- Home /
Question by
StewVanB · Nov 05, 2015 at 06:26 PM ·
uicontrollereventsystemgamepaddelegate
Is there a way to fire the inspector events from code?
I am tasked with converting our game's mouse interface to accept gamepad input. I am hoping that there is a way to fire the events that already exist in our project when a user presses the gamepad buttons.
For example: I have a button that has "Pointer Enter" and "Pointer Exit" events in the Event Trigger inspector element.
I wanted to do:
myButton.gameObject.GetComponent<Event Trigger>().PointerEnter;
or something similar.
Does unity have this sort of functionality or should I just make a completely coded control and have them both do their own things.
-Stew
Comment