I'm trying to do something really simple:
I got two images for my button. The one image should be displayed initially and once the mouse hovers over the button, the other image should be displayed, until the mouse leaves the button.
So far I'm doing it like this:
I defined an Animation for each state and the corresponding transistions inside an AnimationSet. In my update function I constantly pick (orxObject_Pick) the object under the mouse and check if it's one of my buttons. If so, I set the target animation accordingly. In order to change back to the normal button image, once the mouse leaves the button, I have to store the currently highlighted object. So once a object other then the highlighted object is picked, I will set the target animation back to the normal button.
Well this works, but it involves quite a lot of code and configuration(defining animations etc.). If it were only for one button, I wouldn't mind. However I got quite many buttons, so it's kind of annoying. So I wanted to ask you guys, if you know a simpler way of achieving the same functionality?