Search Issue Tracker
By Design
Votes
5
Found in
5.5.2f1
Issue ID
885364
Regression
No
Dragging prefab with serializedObject.ApplyModifiedProperties() into hierarchy during runtime calls OnDisable() method
To reproduce:
1.Download and open attached project.
2.Enter Play mode.
3.Quickly drag "TestObject" prefab into Hierarchy.
4.Repeat step 3 until "OnDisable" message appears in the console.
Expected result: Editor throwing OnDisable message only when object is disabled.
Actual result: Editor throws OnDisable message when GameObject is initialized.
Reproduced with : 5.6.0b9, 5.5.2f1, 5.4.4p4, 5.3.7p4, 2018.3.0a7.
Notes: Bug reproduces after 3 to 4 instantiations of a GameObject. If You open TestInspector.cs script and comment a line where serializedObject.ApplyModifiedProperties() is called the bug does not reproduce.
Comments (3)
-
vzlomvl
Aug 17, 2017 22:22
Reproduced 2017-08-18
• Unity 2017.1.0f3
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Tile Palette grid is moved after entering Play Mode
- Tile Palette Edit mode turns off in Play Mode
- The Editor crashes when Generating Font Atlas in the Font Asset Creator with “9999999999” padding and 256x256 Atlas Resolution
- [iOS] An “ArgumentNullException” error is thrown when GetIntroductoryPriceDictionary() method is called
- Font Import Settings documentation page is missing when the documentation button is pressed in the Inspector window
Resolution Note (2020.1.X):
This is by design and will not be fixed.