How do I use tweens and Delta Time together

Im making a rock band style game, and the notes dont sync sometimes

How do I…

use tweens and delta time together

What is the expected result

TweenTime()*TimeDelta()

What is the actual result

nothings moving

Related screenshots

0.4286*TimeDelta()

A couple of things.

  1. Don’t use a trigger once in the repeat. It doesn’t work the way you think it does.
  2. Why are you setting a tween time by multiplying a small number with an event smaller number? What are you trying to achieve?

So you understand, for 60 FPS, timedelta is the timer elapsed between 2 sequential game frames, around 0.016 seconds. Multiply that by 0.4286, and you get 0.0068576. That’s less than 7/100th of a second or less than 1/2 a game frame. The wait action will be over before the current frame has finished processing. So there’s a possibility that the tween is deleted before it has a chance to start.

I’d suggest you get rid of the wait and delete tween actions. Instead, create a new event with the condition to check if the tween has finished playing, and action to remove the tween.

1 Like