How do I Create random terrain for a 2D above view game

Get help using Construct 2

Post » Tue May 31, 2016 8:48 pm

So I want to make the terrain so some areas are taller than others, each are is made up of blocks whose height is indicated by an instance variable (1-9) But I want all areas to be accessible so I want a block with a height of 9 for example to have at least one 8 block next to it. Any idea how I could make this work?
B
22
S
8
Posts: 203
Reputation: 2,059

Post » Tue May 31, 2016 10:17 pm

What i would recommend is to create a "Fake Wall" the whole terrain is the same level, but the side of a cliff would be a sprite that the player cannot pass.

Otherwise you could do a check for the block next to the player's level and see if it is equal to the current blocks's height +/- 1
B
3
Posts: 2
Reputation: 179

Post » Wed Jun 01, 2016 12:35 am

Well my issue is how to make it random elevation but I figured out a way to do it more or less randomly. I create rows of empty blocks then spawn a real piece of land at a random elevation. If an empty block is next to a piece of land that block will spawn a piece of land with +/- 1 elevation
B
22
S
8
Posts: 203
Reputation: 2,059


Return to How do I....?

Who is online

Users browsing this forum: MadSpy and 6 guests