Tasharen Entertainment Forum
Support => NGUI 3 Support => Topic started by: nguiman on March 30, 2014, 08:05:55 PM
-
Is it possible to set the state of a UIButton to being 'pressed' in code? (via thru NGUI, its collider, or some other method)
There are situations that I want a UI element to be shown in the pressed state, when something else is pressed or some action has occurred. I know I can set the sprite's 'normal' state to use the 'pressed' graphic, but this would require management to reset it back after, I wanted to know if there was a more direct way.
-
No, button logic can't be forced to stay in a pressed state. That would make it a toggle, not a button. If you need that, then just use a toggle.