Detect UI elements being hovered

I want to make some ui effect happen when the user hovers over a button but I can’t detect the element being hovered. I tried the OnMouseEnter and OnMouseExit events but they don’t seem to ever be triggered. I also tried a C# script with the OnPointerEnter and OnPointerExit events but nothing happens. I do have an OnClick custom event called from the button which works.

Any help would be greatly appreciated. Thanks in advance!

You’ll have to use button animator transition, but this also currently only works while in VR, so you need some logic in place to disable the hover effect for desktop if it’s something that for example shows the button name.

Canvas UI button highlight/hover states not working on desktop mode.

Thanks, thankfully is effect doesn’t affect playability so desktop users will still be fine