Hi all.
I’m working on a game with different platforms, and some of the platforms are hidden by simply hidding them in the inspector. I have a ‘Node’ script attached to each platform and use the line of code ‘gameMaster.currentNode = this.gameObject’ to get the current node. Everything is going fine so far, but I noticed when the player enters a platform that’s hidden, the current node doesn’t update, which I assume is because the gameobject is deactivated. Does anyone know how to get this code to work with hidden gameobjects or maybe an alternative line of code? That would be great!
Thanks!
If by hidden you mean set to inactive, then don’t set it inactive, just set the scale of it to 0,0,0 and set the box collider (if there is one) to the same.