- Home /
I found the answer by myself
UI doesn't draw an instanciated prefab but a second one yes. What's going on? Pls Help
I am having an strange behaviour from UI, I have a prefab for basic character UI (Name and health bar). It's same prefab for any character. However with some characters it's not draw. If I check scene view, the prefab is there, have correct values, everything is OK, but not drawing. It's comple to explain so, I'll illustrate it.
Here is the hirearchy:
And here is the Scene View
It's exactly the same prefab for both... but one is drawn and the other not. Why? And it's not related to instantiation order, I can swap order (A became B and B became A) and have same result.
Any ideas?
P.D: I am using Unity LTS 2018.4.xx
Thanks.
Found the problem, it was related to canvasGroup.alpha and a wrong "if" question, setting up the alpha to 0.
Follow this Question
Related Questions
Using raycast to enable canvas that is linked to a prefabs gameobject 0 Answers
Instantiate rect transform objects 2 Answers
UI prefab instantiation problem 1 Answer
UI prefabs in bundles are taking huge large size 1 Answer
Prefab a 2D UI? 1 Answer