Search Issue Tracker
By Design
Votes
0
Found in
2017.4.0f1
2018.4.0f1
2019.2.0a1
2019.2.2f1
2019.3.0a1
2020.1.0a1
Issue ID
1179127
Regression
No
GameObject.Find() returns wrong value when GameObject name is the same as existing Hierarchy path
How to reproduce:
1. Open attached project ("UnityFindbug.zip") and open SampleScene
2. Enter PlayMode
3. In Game view click on the top left button.
Expected result: GameObject.Find() method returns requested GO
Actual result: GameObject.Find() returns last object from the string used in method
Reproducible with: 2017.4.32f1, 2018.4.7f1, 2019.2.3f1, 2019.3.0b1, 2020.1.0a1
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
- Crash on ShaderLab::ShaderState::ApplyShaderState when entering Play Mode and calling ShaderWarmup.WarmupShaderFromCollection with a shader that has dynamic_branch
- Crash on operator delete[] when a serializable structure in the System namespace is serialized by a MonoBehaviour
- [macOS] forward and backward mouse buttons are recognized as middle mouse button
- NavMeshModifier.OnEnable/OnDisable gets progressively slower when called repeatedly
- "System.Net.CookieContainer" throws an "ArgumentException" error when using a non-UTF-8 machine locale and hostname
Resolution Note (2020.1.X):
This is legacy behavior and by design. We recommend that users give their game objects unique names to avoid this issue.