How to make an infinity game

Hi everyone,

I’m making a game similar to “Snake vs Block” and I’m having trouble figuring out how to make it infinite. I have created a set that includes all the blocks, power-ups, and other elements. My idea is to create a code logic that respawns this set once the current set is finished, allowing the game to loop endlessly. However, I’m stuck on how to implement the logic to respawn the entire set once the existing set is completed. Does anyone have any ideas on how to achieve this? Any help would be greatly appreciated!

Here is the SS of like one set this is i am trying to respawn

Privacy & Terms