I deactivate a button when it is pressed, but unfortunately anything behind the button is pressed as well.
Hey there, I have a script that keeps the mouse from clicking anything that is under UI, so that when the player hits a button, they are not also interacting with the game. The problem I've run into is that one of my buttons disappears when you press it. It's like a one time use. At the exact same time it disappears, the mouse clicks anything under it. I'm not really sure what to do about this, and was hoping I could find some help here. Any ideas are appreciated!
Answer by harperrhett · Aug 04, 2020 at 02:31 AM
I ended up fixing this by putting the stuff that my button activated through LateUpdate().
Your answer
Follow this Question
Related Questions
How do I ignore Mouse Clicks with new Unity UI 0 Answers
Is there a way to detect if a button is pressed if it isn't created programatically? 2 Answers
Click Button and Follow Mouse 1 Answer
HOW TO MOVE A OBJECT TO ANOTHER OBJECT SMOOTHLY NOT INSTANTLY? 0 Answers
All UI elements break when setting resolution through script. [please help] 0 Answers