Hey guys, so I have worked with Unity’s UI System for a while now, enough to be able to say I’ve possibly gone through every annoying scenario there is. And yet I can’t fix this one.
When I click on my button, sometimes it is responsive. Sometimes, it is unresponsive. But it is ALWAYS responsive when I apply a tad bit extra pressure on the mouse button. Any idea what might cause this?
Some things that might matter:
- My buttons are actually text components, with the highlighted button having an image in front. The image moves up and down between the different buttons.
- There are animations occurring, for example:
- When you hover over the button, the text and the hover image increase in size.
- When you click on a button, the other buttons decrease in size, to 0.
“But it is ALWAYS responsive when I apply a tad bit extra pressure on the mouse button. Any idea what might cause this?”
Sounds like a broken mouse.
If your mouse is not broken then you are misconstrued; it is the extra time rather than the extra pressure. You do not have analogue buttons on your mouse.
Hello there,
As said above by meat5000, the pressure you put on your mouse should not matter here. One thing I would definitely check though, is that all the UI elements that might be in front of your button have their RaycastTarget flag set to False. If not, they may interfere with your clicks (depending on how your UI is setup).
I hope that helps!
Cheers,
~LegendBacon