Topic was automatically imported from the old Question2Answer platform.
Asked By
asetyowatir
Hello, I’m new here. I want to create a tween to loop forever, with this setting :
a sprite which it’s alpha will go back and forth from 0 to 1
Something like ping-pong / flip-flop looping.
I have tried making a 2 tween, one for 0 to 1 the other for 1 to 0. After that I have tried calling it with on tween complete to start each other but it just running once and done.
Someone please guide me trough this, thank you for reading.
Or you could set up two tweens and make them call each other at the tween_completed signal. Connect the signal via the inspector tab “signals” or via code:
What happens when everything is dynamic? AnimationPlayer might not work
shakemakesgames | 2022-02-05 18:51
Sorry to necro, but it’s an XY problem. The first thing I though was looping tween for a certain animation, because I wanted easing. So I googled how to loop tweens in Godot. However, this answer reminded me about the AnimationPlayer, which is what I really needed. I can easily create easing with keyframes, looping is supported out of the box, and animations can be created declaratively in the editor, so no extra cluttering in my scripts.