• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Playing with random terrain generation

Status
Not open for further replies.
Level 3
Joined
Mar 30, 2022
Messages
7
Hello everyone !

I'm making a survival map for multiplayer. One of its features is random terrain generation.

People need to build bases (with walls and towers) to protect against undead players

Here are some generator results. I just wanted to share and hear some opinions.
 

Attachments

  • 1.png
    1.png
    4.2 MB · Views: 140
  • 2.png
    2.png
    4.3 MB · Views: 141
  • 3.png
    3.png
    4.4 MB · Views: 126
  • 4.png
    4.png
    3.7 MB · Views: 123
  • 5.png
    5.png
    4.3 MB · Views: 140
Level 14
Joined
Sep 28, 2011
Messages
968
You should probably avoid near perfectly round lakes, this looks eerie and supernatural.
Was that the effect you were aiming for?
Likewise making some cliffs be single huge terrain deformations looks odd.
Do you fear causing too many leaks with terrain deformations?
 
I love me some random terrain generation! Wonderful to see!

The mountains could be improved by introducing some additinal noice on top of the "Shablam! Round, smooth mountain". I'd probably use some multi layered perlin noice with some fractals to achieve it, but as long as it looks good :p

I agree with the feedback on the lake, it could use some adjustments to how the shape is done.
 
Level 3
Joined
Mar 30, 2022
Messages
7
Thanks. I agree with you both.

My aim is to create reliable, organic, and playable terrain. I want not just decoration but an interactive landscape, which players can use (to build ease defendable bases, to be able to hide or use terrain as advance). I don't like fixed locations on survival maps (like Troll and Elves), so I thought it would be nice for players to have a new terrain in each new game.

Right now it's a beta version of this generator. I know how to make complex shapes of lakes and mountains, but I have some issues with water.

About leaks. Well, I didn't notice any leaks or after-generation game lags. My generator is simple and right now its takes around 15 seconds max. to generate a map.

About Perlin noise, I tried. Maybe I did something wrong, but it's not gonna work. Warcraft 3 engine has a limitation in the executive function queue, and it does not execute a function if you overflow the queue. Maybe it will work for local small areas, but not for whole map.

Here is a complex shape lake, but with water overlapping each other. I'm also planning to add decorations (bushes, roks, flowers...), and the next terrain structure will be hills
 

Attachments

  • 6.png
    6.png
    4.3 MB · Views: 50
Level 3
Joined
Mar 30, 2022
Messages
7
What do you mean by " calculate on one row/tick". Is it something like "each 0.01 second do function "?

I saw once a project Noise Library ( Noise Library v1.2 ) but they calculate action every 0.01 second (manually slow down function)
Unfortunately, they have only a 32x32 map, so it will be very long to calculate in larger map areas.
 
What do you mean by " calculate on one row/tick". Is it something like "each 0.01 second do function "?

I saw once a project Noise Library ( Noise Library v1.2 ) but they calculate action every 0.01 second (manually slow down function)
Unfortunately, they have only a 32x32 map, so it will be very long to calculate in larger map areas.
Yes, some thing like that, but maybe it's too slow. I've seen people say that triggers are processed every 0.03125 seconds. I have not done enough research to confirm, but I was thinking of processing 1 row every that much time.
 
Level 3
Joined
Mar 30, 2022
Messages
7
Wow 0.03 seconds, that much slower than I thought. Thanks for the information. Maybe it will work if we will proceed with 1 row per tick. I will try to test it. if it will work, we could possibly use it for tile texture mapping.

My system is more.. random. It takes random coordinates on map and puts structure in that point (forest, mountain, lakes). Each time system chek if is there some structure near this point to avoid collision between them. I use dummy units to store locations and data on structure

Each structure has its own number - this is the number of structures of a particular type that should appear on the map
For example, it will be 300 forests, 200 mountains, and 150 lakes that will spawn on the map
 
Level 3
Joined
Mar 30, 2022
Messages
7
Thank you, Rui it's nice to hear that:grin:. If its gonna work I will write down the complete algorithm of my Generator (of course with a map example)
 
  • Like
Reactions: Rui
Level 14
Joined
Sep 28, 2011
Messages
968
Awesome endeavour! Looking at Similar Threads, random terrain generation has been tried before, but seemingly no one achieved it. It would be invaluable for many maps, I reckon. May you find success! :)
What do you mean?
There is already multiple maps using random terrain generation.
Just no melee maps because it is incredibly hard to make a randomly generated melee terrain that is balanced and fun to use (I tried a few times).
 
Status
Not open for further replies.
Top