• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

Infinite looping drawn background

6

66Gramms

Guest
Hi all!
I'm making a parallax background which is made from more than 7 elements so I can't use the room's default editor for making it so i'm drawing it by code.
draw_background (bg_example, x1, 0)
x1 is a variable which i decrease every frame, so i have my parallax this way... But the problem is I don't know how could I loop the backgrounds horizontally? I didn't find any code for it, and it just run off the screen like this. Can you help me out with this please?
 
Top