Search Issue Tracker
Won't Fix
Votes
1
Found in
2018.4
2020.2
Issue ID
1235386
Regression
No
UI Image doesn't appear in the Player when using a specific project
How to reproduce:
1. Open the uploaded project's Scene labeled "MainScene"
2. Enter the Play Mode
3. In the Game View, use the scroll wheel to change the weapon UI
4. Observe the behavior
5. Go to File->Build Settings
6. In the Build Settings Window, press the "Build And Run" button
7. In the Build, use the scroll wheel
8. Observe the behavior
Expected result: UI appears in the bottom-left corner when the weapon is switched
Actual result: UI doesn't appear for the switched weapon
Reproducible with: 2018.4.21f1, 2019.3.10f1, 2020.1.0b5, 2020.1.0a7
Couldn't test with: 2017.4.39f1 (Errors are thrown)
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 D3D12CommonShader::ApplyGpuProgram when attaching material which samples "_UnityFBInput0" to "Full Screen Pass Renderer Feature" Component
- SpeedTree meshes and objects count differs when comparing the numbers in the Player with the Editor
- Model and Prefab Preview icons are not updated after upgrading associated Materials to URP
- Game view is rendered white when viewing the Editor with HDR display and Post Proccesing is enabled on the Main Camera with 2D URP
- UI Builder doesn't update the style sheet when using "Extract inline style" right-click option
Resolution Note (2020.2.X):
Seems to be caused by order in which WeaponHUDManager and PlayerWeaponsManager are executed. Making WeaponHUDManager run first in script execution order settings fixes issue in player too.
PlayerWeaponsManager in Start() calls AddWeapon() method which instantiates weapons and invokes onAddedWeapon UnityAction.
Meanwhile, WeaponHUDManager in Start() registers its method responsible for UI to onAddedWeapon action. So if Start() in PlayerWeaponsManager is executed first, HUD’s UI method is not registered yet and so UI doesn’t get created.