How can I stop them from drifting apart?

I have these lasers and platforms done with a timeline and in the Editor they work perfectly fine, but when I start my Project as a game, they keep shifting apart… I don’t what causes this or how I can fix it, so if someone could enlighten me, that would be really great.

You have to fix the start and endpoints when you want to animate with a timeline. In your code, you are sampling the object location during the timeline, this will lead to all sorts of weirdness… :wink:

( just calculate the start and endpoints first and put them in variables )

I’m sorry, I’m fairly new to Unreal, but how would I do it the way you described it? Like how would the blueprint look like… sorry for bothering you, with this stupid questions…

Like this:

Also much easier to use SetRelativeLocation. That way you don’t have to worry about X and Y.

PS: The TL just goes from 0-1.

I made the blueprint like this, but now the actor is somewhere in the level and doesn’t move properly… I’ll keep trying and thank you for your help :wink:

Show me your code…

If you still want to do it with SetActorLocation, you have to also store the X and Y before the timeline and just plug them into the SetActorLocation node…

I forgot to plug the X and Y values… thanks you very much, now it’s working :wink: