Search Issue Tracker
Fixed in 2020.1.X
Votes
0
Found in
2017.4.0f1
2018.4.0f1
2019.1.0a1
2019.2.0a1
2019.3.0a1
2019.3.0b1
2020.1.0a1
Issue ID
1186393
Regression
No
Child GameObjects with transform.SetAsLastSibling() in OnDisable aren't always disabled when parent is disabled
Steps to reproduce:
1. Open attached project "1186393.zip"
2. Open "SampleScene"
3. Enter Play mode
4. In the Hierarchy -> dropdown "Canvas" GameObject child list -> dropdown "Panel" GameObject child list
5. Disable one of the parent GameObjects, either "Canvas" or "Panel"
Expected results: All child GameObjects are disabled
Actual results: Half of the GameObjects are disabled
Reproducible with: 2017.4.32f1, 2018.4.10f1, 2019.1.14f1, 2019.2.7f2, 2019.3.0b4, 2020.1.0a5
Notes:
- Disabling parent GameObject disables half of the child GameObjects
- If parent GameObject is disabled and half of the child GameObjects are active, then disabling parents parent disables half of the GameObjects that are active and should have been already disabled (can be seen in the attached video "vsFok7wDND.mp4")
- If you go out of Play mode while the script has transform.SetAsLastSibling(), unity crashes (case 1186891)
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
- Some UXML Template Asset foldouts appear enabled when all fields inside are disabled
- URP Terrain Demo crash on burst_signal_handler after Generating lighting
- Project window button icons are poorly visible and their shades differ in Light theme
- GC.Alloc called by HDRenderPipeline.LensFlareMergeOcclusionDataDrivenPass() when playing the default HDRP Sample Template project
- Automatic LOD fails and SRP Batcher incompatibility occurs when using spline-based quad-topology meshes
Resolution Note (fix version 2020.1):
Fixed in 2020.1.0a20