I'm trying to create a special level in my game where the spaceship travels in circles to a space station. (which appears to rotate as it is made up of 8 frames).
The viewport view does not move.
Only stars and nebulae move (family called axis).
my idea was to make it so that when the nebulae and stars go out of the layout width they return to x=0.
When their x value goes below 0 they go back to 3416. (the viewport size for x is 854).
But obviously something is wrong.
Probably I'm missing something that I should consider and so I ask you, maybe there is someone who immediately understands what is the problem.
So how should I do it?
I also leave a screenshot of the code I tried and a link to my google drive to download the c3p file (if needed).
https://drive.google.com/file/d/1OybYrRKOcEAyl3wyJ0UvcNrvxDuSI0QT/view?usp=sharing