TextureButton - change texture with animation on hover

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By JeremyCoco

Hello!

I want animate changing texture with Tween when user hover on button but I dont know clearly how to do that.

In the simple way I just want delay change texture from normal to hover because it’s changing to fast.

For example like there:

:bust_in_silhouette: Reply From: Jowan-Spooner

Unfortunately, there is none such feature implemented yet.

If it’s only about a single color changing slower you could use an AnimationPlayer node, add an animation where the color of the button is changing to the color you want. Then connect the signal mouse entered of your Button and start the animation via code. The same for exiting the button. (Well, I know this is a lot to for such a thing, but…)
Would recommend to change the color of the button by animating the property self modulate in the inspector. You could also change the color of a TextureButton this way.

Good Luck