Search Issue Tracker

Fixed in 2020.1

Fixed in 2019.3

Votes

0

Found in

2019.3.0b5

Issue ID

1187140

Regression

No

[Preset] Properties are not visible and MissingComponentException error is thrown on selecting Tree preset asset

IMGUI

-

Properties are not visible and MissingComponentException error is thrown on selecting Tree preset asset.

Steps to repro:
1. Create a new project.
2. Gameobject > 3D Object > Tree.
3. Create a Preset of Tree.
4. Select the newly created Tree object in the Project View.

Actual Result:
Properties are not visible and error is thrown in the console.

Expected Result:
Properties are visible and no error is thrown in the console.

Reproducible in:
2020.1.0a6, 2019.3.0b5, 2019.2.0f1, 2019.1.0f1

Environment:
Windows & Mac.

Stack trace:
MissingComponentException: There is no 'Renderer' attached to the "" game object, but a script is trying to access it.
You probably need to add a Renderer to the game object "". Or your script needs to check if the component is attached before using it.
UnityEngine.Component.GetComponent[T] () (at <5e35e4589c1948aa8af5b8e64eea8798>:0)
TreeEditor.TreeEditor.DrawHierachy (TreeEditor.TreeData treeData, UnityEngine.Renderer renderer, UnityEngine.Rect sizeRect) (at <52c46852ed4749ed926125cda2005635>:0)
TreeEditor.TreeEditor.InspectorHierachy (TreeEditor.TreeData treeData, UnityEngine.Renderer renderer) (at <52c46852ed4749ed926125cda2005635>:0)
TreeEditor.TreeEditor.OnInspectorGUI () (at <52c46852ed4749ed926125cda2005635>:0)
UnityEditor.Presets.PresetEditor.DrawInternalInspector () (at <52c46852ed4749ed926125cda2005635>:0)
UnityEditor.Presets.PresetEditor.DrawPresetData () (at <52c46852ed4749ed926125cda2005635>:0)
UnityEditor.Presets.PresetEditor.OnInspectorGUI () (at <52c46852ed4749ed926125cda2005635>:0)
UnityEditor.UIElements.InspectorElement+<>c__DisplayClass53_0.<CreateIMGUIInspectorFromEditor>b__0 () (at <52c46852ed4749ed926125cda2005635>:0)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.