Search Issue Tracker
By Design
Votes
0
Found in
2021.3.20f1
2022.2.9f1
2023.1.0b7
2023.2.0a5
Issue ID
UUM-29845
Regression
No
Sprite Renderer on Prefabs instances is not destroyed after exiting Play mode when Sprite Renderer is instantiated from Tilemap
Reproduction steps:
1. Open the attached “Test.zip“ project
2. Open “SampleScene” scene
3. Delete “Tilemap” GameObject and undo the change
4. Observe the Scene window
5. Enter and exit Play mode
6. Observe Scene and Hierarchy windows
Expected result: “Cell” Prefab instance disappears after exiting Play mode
Actual result: “Cell” Prefab instance doesn’t disappear in Scene and Game windows after exiting Play mode
Reproducible with: 2021.3.20f1, 2022.2.9f1, 2023.1.0b7, 2023.2.0a5
Could not test with: 2020.3.46f1 (Due to errors in the Console window)
Reproduced on: macOS Monterey 12.6 (Intel)
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
- Blank, Light-Themed "Create Node" window becomes visible on the next project open
- UI Elements/Layout inconsistencies in the Particle System component
- The Game view and Scene view fail to render when launching the Editor with a maximized Render Graph Viewer window
- "List is empty" is poorly visible in the "Create Node" window
- [Android] GameObject with a custom shader becomes invisible when deployed with the Vulkan Graphics API
Resolution Note:
When the scene is loaded with the Tilemap, we will instantiate the GameObject for each Tile on the Tilemap, but hide it in the Hierarchy window. This will help the user visualize the instantiated GameObject while the user is editing the scene.
When entering PlayMode, the GameObjects are instantiated to their defaults and shown in the Hierarchy window. This allows the user to interact and debug the instantiated GameObjects as their game is player.
When leaving PlayMode, these GameObjects are destroyed. They are then instantiated again and hidden in the Hierarchy window, just like when the user loaded the scene, for the visualisation reasons.