Script Error: Looping overlay

Hello! I need a little help here. :face_with_monocle:
I’m trying to make something like this:

image

But in my case, the ball would be going up and down as it rotates, all simultaneously.
This is my code:

@overlay NAME rotates 360 anchor point 0.5 0.5 AND NAME shifts to 113 242 in zone 1 in 2 THEN overlay NAME shifts to 114 217 in zone 1 in 2 loop INFINITE times

The message “’@overlay NAME rotates 360 anchor point 0.5 0.5 AND NAME shifts to 113 242 in zone 1 in 2 THEN overlay NAME shifts to 114 217 in zone 1 in 2 loop INFINITE times’ is not a valid direction command” keeps appearing to me.

Can someone please tell me what I’m doing wrong?

1 Like

You forgot the word “overlay” in one spot. Try:

@overlay NAME rotates 360 anchor point 0.5 0.5 AND overlay NAME shifts to 113 242 in zone 1 in 2 THEN overlay NAME shifts to 114 217 in zone 1 in 2 loop INFINITE times

I didn’t notice lol, thank you!
But it’s still not working.
Now it’s the message “Loop command can only be used with Overlay Animation commands”

Try separating the command like this:

@overlay NAME rotates 360 anchor point 0.5 0.5
@overlay NAME shifts to 113 242 in zone 1 in 2 THEN overlay NAME shifts to 114 217 in zone 1 in 2 loop INFINITE times

I managed to do something that worked for me, thanks for your help!

1 Like

You can only use “THEN” in the looping command. You’re getting this error because you have an “AND” in the loop.

And since this is an infinite loop, you must never use a “@” sign but “&”, otherwise the scene will not proceed and stuck on the loop.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.