#Game object can't be find in Unity

1 messages · Page 1 of 1 (latest)

rigid jolt
#

Hi, my script cant find game object winpanel in unity which is already created. Try a lots of diffrent code but still not working :/

red fiber
rigid jolt
#

is enabled in play mode

#

i can shere with you my screen

#

it took me 5 hours to fix it but im almost give up :/

red fiber
#

I would just directly serialise a reference to it into a UI manager and use the singleton pattern to access it.
I think there's barely ever a reason to use Find, it being hard to debug is one of the reasons to avoid it

rigid jolt
#

but one of my game object is in other scene and need to use another object from the other scene

#

the first object is moved to the other scene in dont destroy on load and has bject to find the other object and use it]

#

this winpanel i had created in scene,but with no reason playerinfo cant find it

red fiber
#

A singleton would make accessing it easy then

rigid jolt
#

i will try