How do I create procedural walls?

  • I would like to make a very simple game similar to this:

    https://youtu.be/q4Q27tciZ5U

    Since it never ends, I assume the cave walls are procedural?

    How can you make procedural walls in Construct?

  • Can't be done?

  • Hmm there are tons of ways to do it. Not sure how to explain how to do procedural walls, just add some condition for createObject action though not using createObject would probably be better for performance if you can think of a way to do it like reusing "old" objects.

    I would probably just have set of wall pieces moving left that I'd randomly teleport beyond the right edge or something like that.

    Or you could have few instances of one wall object that you rotate and move around.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • 3DPiper you are wrong it can be done. C2 to is capable of anything if you think and code logicly.

  • Thank you for the replies

    [quote:1vu8hu2x]Hmm there are tons of ways to do it. Not sure how to explain how to do procedural walls, just add some condition for createObject action though not using createObject would probably be better for performance if you can think of a way to do it like reusing "old" objects.

    I would probably just have set of wall pieces moving left that I'd randomly teleport beyond the right edge or something like that.

    Or you could have few instances of one wall object that you rotate and move around.

    I was thinking of having a rectangle object that I could scale horizontally while skewing vertically. Then for each 'turn' in the cave, add another rectangle to the end with the skew going in the opposite direction. I'm not sure how to line up the ends, though. Plus, the example has the whole cave slowly tapering. However, I don't see those distortions available in C2.

    [quote:1vu8hu2x]3DPiper you are wrong it can be done. C2 to is capable of anything if you think and code logicly.

    I'll be honest, I was hoping for a little more than "yes, it can be done". I posted "How do I create procedural walls" hoping for an answer or hopefully an example. Did I post in the wrong place?

  • I tried something with tiles, have a look:

    https://drive.google.com/file/d/0B5FlDY ... sp=sharing

  • The procedural portion of it is easy. you can think of the whole cave as just a polyline since the top and bottom walls turn at the same x position. So then you just need a bunch of random y values. The visual part of it just needs some way to draw a polygon (canvas or paster plugins can do this).

    Here's one possible example:

    https://dl.dropboxusercontent.com/u/542 ... hrink.capx

  • Wow, thank you guys, I will see if I can decipher your examples

  • Hound to rescue

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)