2D Ground, really long, how?

What’s the best way to make a really long ground in a 2D game? I mean, massively long, like 20, 40 or even 100 screen widths long.

Needs physics. Has a tiling texture.

Well, there are a couple ways you could do it. Just make 1 platform and set its width to your large value to be as big as you want. Or you could place a bunch smaller ones yourself. Or even you could generate the platforms as you move along the path. I’d say if there are any “cutscene” like things, breaks in the gameplay, or something like that, I’d say break it up. If you do it with code, it could be an easily adjustable length to perhaps just keep adding platforms the further you go, so it would automatically stop whenever you decide to have the player finish the level or end the game or whatever.


I think figuring out the best approach to it would depend on the type of game that you are trying to make. If there are repeated areas on the level, I’d say break it up into chunks and spawn them in. If every part of it is unique, maybe just making a really long collider would be fine.