- Home /
Problems getting UI elements to activate/deactivate on mouse over?
Hi All,
Just working on a school project and I came into an issue. Previously I've used on mouse over to make text activate/deactivate in the game world. However it doesn't seem to work on UI features. I was attempting to make a semi-transparent panel activate/deactivate on mouse over to create a UI effect; I have already unlocked the cursor and made it visible. Does anyone know what I need to do to make this happen? I have heard of on pointer enter, will this accomplish what I need?
Many thanks in advance.
Answer by skildfrix · May 08, 2019 at 04:55 AM
You can use EventTriggers built-in with Unity3D. Select a gameobject > Add Component > Search "EventTrigger" > Add the EventTrigger you want > Assign the public function you wanted to call upon trigger. You can also add EvenTriggers with script. Please read the documentation about that here.
Your answer
![](https://koobas.hobune.stream/wayback/20220612200929im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Multiple Cars not working 1 Answer
Distribute terrain in zones 3 Answers
How can i scale a ui Panel from the left side only ? 2 Answers
Panel GameObject not activating 0 Answers
Panel GameObject not activating when called from another script 1 Answer