Random Terrain

Singleplayer Maps here.

Random Terrain

Postby darkstar 1 » 18 November 2018, 16:49

.:RANDOMLY GENERATED TERRAIN:.

MAP ID: darkstar 1-rand
MAP PAGE
MAP DEMO

In this map a random terrain (with trees) is generated, after it's generated you can press E to spawn enemies and fight them on the random terrain.

- There are 200 small movables, a max of 20 wide movables and a max of 10 trees atm.
- Random generation stops after small movable 200 is placed, even when not all wide movables or trees are placed.
- Trees can be destroyed by damaging the trunk.

Screenshots:

Spoiler: Show More






User avatar
darkstar 1
Proxy [700]
 
Posts: 712
Joined: 13 September 2014, 13:20
Location: Here... or there :|

Re: Random Terrain

Postby TheGoldenMaster » 19 November 2018, 08:19

when it was generating,i feel it was like minecraft generating world. oof
User avatar
TheGoldenMaster
Recruit
 
Posts: 23
Joined: 5 August 2017, 11:56

Re: Random Terrain

Postby Guardsman » 20 November 2018, 03:02

I really want to know how you randomly generated random movables to random locations. This was amazing. You have clear talent with stretching the limits with the PB2 Advanced Level Editor.
REET

Guardsman
Cyber Grub [25]
 
Posts: 25
Joined: 2 October 2018, 00:51

Re: Random Terrain

Postby darkstar 1 » 21 November 2018, 23:06

TheGoldenMaster wrote:when it was generating,i feel it was like minecraft generating world. oof

Don't dare to compare my map with minecraft, I've already made a minecraft map for that >:(

Guardsman wrote:I really want to know how you randomly generated random movables to random locations. This was amazing. You have clear talent with stretching the limits with the PB2 Advanced Level Editor.

It's actually rather simple.

It just adds a random value ranging from -50 to 50 to the Y position, and adds 50 to the x position every time, then it executes a bunch of triggers with one call (which each move a door to the region), but only one is always activated and they activate others when executed. (Also, when using the execute trigger action, execute them in reversed order, otherwise they'll activate each other before the next execute trigger action is run and they'll cause a chain reaction, moving all the doors to the region at the same point).

Test map here, it's open sourced, it's probably easier to understand than the text above.
https://www.plazmaburst2.com/?s=9&a=&m=darkstar%201-rand%20test&id=916089

Also, I think the lower the value in the timer the higher the chance that pb2 fails to run it, probably the reason why sometimes the random terrain isn't generated in the original map.



User avatar
darkstar 1
Proxy [700]
 
Posts: 712
Joined: 13 September 2014, 13:20
Location: Here... or there :|

Re: Random Terrain

Postby Guardsman » 22 November 2018, 22:09

That's really interesting! I never tried to mess with variables in PB2 prior to seeing this, I'll definitely play around with that! Thank you.
REET

Guardsman
Cyber Grub [25]
 
Posts: 25
Joined: 2 October 2018, 00:51


Return to Singleplayer Maps

Who is online

Users browsing this forum: No registered users