Jump to content

[Random Map] Realistic Terrain Demo


FeXoR
 Share

Recommended Posts

post-14196-0-21066000-1395580187.jpg

The grass colours might look strange, still I like the variation. I remember being in the alps and finding places where it was really nice with many plants, while the overall impression was rocky. Isn't it related to overly many factors like wind, how much humus, if fungi, lichens are around, e.g. moss fern.

Your generation reminds me of this:

post-15921-0-24940900-1395892913.jpg

800px-MJBC-jardin-la-Thomasia-Bex-CH-1.j

In spite of the relative low altitude, 1260 meters, its situation at the entrance of the Vallon de Nant, a small glacier valley, induces a subalpine climate to the garden.

So the textures could take neighbour textures into account. Like: if there are snow-textures, choose from this set of biome textures. Looking at your results, I guess you are already doing this or even something more elaborated.

Height and slope sound real. Lichens are the first to settle on rock and difficult slope. usually in mountains it's an alternating process. Between rocks being grown over first by lichens .. later by others, then a rock avalanche might reverse the process.

Thanks for sparking yet another idea. We could create avalanche animations. I have to find out how this could be made to affect units. So snow or stones pull them apart, trees and animals too of course.

Don't give up, what you have shown so far is already the utmost incredible.

post-14196-0-21186800-1395580152_thumb.j Also the map overview. Really encouraging results.

Edit: Had to employ a really interesting teqnique to post google static images (forum doesn't allow it usually).

post-15921-0-24940900-1395892913_thumb.j

Edited by Hephaestion
  • Like 1
Link to comment
Share on other sites

  • 2 weeks later...

Hm, got a javascript question:

What's the difference of defining a class function inside the body with this.function_name = function () {blablub}

or outside the class body with class_name.prototype.function_name = function () {blablub}

Code:

function Environment(name){this.name = name;this.SkySet = "default",this.SunColour = {r: 0.749020, g: 0.749020, b: 0.749020, a: 0},this.SunElevation = 0.785398,this.SunRotation = 5.49779,this.TerrainAmbientColour = {r: 0.501961, g: 0.501961, b: 0.501961, a: 0},this.UnitsAmbientColour = {r: 0.501961, g: 0.501961, b: 0.501961, a: 0},this.Water = {WaterBody: {Type: "default",Colour: {r: 0.3, g: 0.35, b: 0.7, a: 0},Height: 5,Waviness: 8,Murkiness: 0.45,Tint: {r: 0.28, g: 0.3, b: 0.59, a: 0},ReflectionTint: {r: 0.28, g: 0.3, b: 0.59, a: 0},ReflectionTintStrength: 0.0}},this.Fog = {FogFactor: 0.0,FogThickness: 0.5,FogColor: {r: 0.8, g: 0.8, b: 0.8, a: 0}},this.Postproc = {Brightness: 0.0,Contrast: 1.0,Saturation: 1.0,Bloom: 0.2,PostprocEffect: "default"}// this.deploy = function()// {// g_Environment = this;// }}Environment.prototype.deploy = function(){g_Environment = this;}

As is it works.

Using the documented out code (inside the class body) Atlas starts but never finishes the random map.

Edited by FeXoR
Link to comment
Share on other sites

What's the difference of defining a class function inside the body with this.function_name = function () {blablub}

or outside the class body with class_name.prototype.function_name = function () {blablub}

Inside is useful if you wish to use 'local' variables.

e.g.

function MyClass() {    //private:    var local_counter = 0;    //only this way you can use the private variable above:    this.countUp = new Function() {        ++local_counter;    }}
The prototype.<funcion> will be inherited by all derivatives (i.e. subclasses and their instances).

So far what I know.

Edited by Hephaestion
Link to comment
Share on other sites

I had something wrong above: local is clear already, private it should be. The function not assigned via prototype is the only chance to have private variables.

I think it's convention, to put it in the class body directly only if you desire this private functionality. Else better keep it outside.


@FeXoR:

We talk about snow here. It involves a local duplication of the terrain (only visually) that varies in height to emulate the snow fallen so far.

In summer the height sinks due to melting, the snow-height also depends on height of the local part on the map.

To have it not as a exact duplicate of the underlaying terrain-height would look more natural. Do you know of a function that would give the snow-height visual layer a bit of a natural variation (in height => form)?

The snow-height depending on altitude could be solved by a linear function.

Unfortunately it seems difficult to find snow-height variation data over altitude. Mostly it's snow-height variation over years (due to climate hype).

Also this might be of use for us:

Ten inches of snow is equivalent to about one inch of rain.

(abel.math.harvard.edu/~divac/SAR/pchap1.pdf‎)

I also thought about the possibility of a global wind factor, needn't be local (too complex?), but should be able to change over time.

Though I wonder myself which effect this wind should have. And how to visualise this wind?

You are the natural functions expert here, so I thought I'd come by your thread and lay siege to it. ;)

Link to comment
Share on other sites

Thx for the answer.

Concerning the snow:

I only have a decent overview about RMGEN codebase and not the simulation code (or the engine) so I can't help you here.

The "only visual" height change is also used for terrain flattening underneath buildings AFAIK so maybe you could look there.

The function would be similar to erosion functions like in here.

I also played around with rain amount depending on height (a linear function did do fine).

A function to redistribute the snow locally might be similar to getAdditiveWindErrosionedReliefmap() in the above linked map (only 8 possible directions though since tile, not vector-based but fast).

A global wind strength parameter will do fine (the local effects could be (randomly) determined in the functions doing things with wind involved).

An additional parameter like "windBumpiness" would be helping though.

I have no idea where those global parameters should be invoked (guess right in the C++ code since e.g. tree movement depends on it).

Ofc. the map/RMS designer should be able to set it.

Edited by FeXoR
  • Like 1
Link to comment
Share on other sites

  • 1 month later...

I noticed that the derivateEntitiesByHeight function does not work correctly. With some seeds you will encounter entities that are placed inside (or at least do not keep the required distance) the CC, while it should avoid starting locations with a certain distance. As a workaround I personnaly avoided the playerHeight in Schwarzwald.

Link to comment
Share on other sites

I'll check this. ATM I got no time though. May take a month to get back to the random maps but I really intend to finish this map until end of the next free period (in about 3 months). I'm sorry for this taking so long as well but I need to proceed in my real live.

Link to comment
Share on other sites

  • 1 month later...

I'm working on a new random biome system.

(I can't advise to do such thing because it's sooo boring...)

However, I'm OK with the alpine biome so far.

Input about the alpine biome, the hightmap in general and the random biome systems structure (so far, heavily work in progress, not used yet) very welcome.

Some screenshots (sadly with very poor graphics settings ATM):

post-14196-0-34130700-1407066423_thumb.jpost-14196-0-16713100-1407066429_thumb.jpost-14196-0-55138200-1407066434_thumb.jpost-14196-0-49587000-1407066440_thumb.jpost-14196-0-42810700-1407066447_thumb.j

Conclusion:

- Cliff detection comes out quite nice

- Stones placed on rough terrain are not sunken deep enough into the ground, so somehow "flying" (PLZ fix that)

- Reachability of all trees are not guaranteed but I never encountered unreachable trees (However, I really think the unit AI should handle this)

Edited by FeXoR
  • Like 1
Link to comment
Share on other sites

Well, only for random maps ^^

And I may have to adjust it to fit the engines passability detection since it might be weird if units can walk on some parts of cliffs and can't on other parts.

For now it's just for texture placing.

(Still work in progress)

Oh, and forgot to append the RMS:

RealisticTerrainDemo2014-8-3.zip

Edited by FeXoR
  • Like 1
Link to comment
Share on other sites

  • 8 months later...
  • 8 months later...

Please re-categorize random maps according to terrain type and map size, ex: Random Alpine (giant), Random Savannah (medium), etc.

Most of the time, I always end up playing as Ptolemies in a Snowy Alpine map, or the other way around, playing as Britons in South Asia (India) or as Indians in Arctic climate, which is kinda lore-breaking. :(

Link to comment
Share on other sites

@elexis: I agree. Belgian Uplands and Schwarzwald allready use them and the functionality is extracted in a library in my working copy.

@wackyserious: I also argee with a recategorization of random maps. However, for the climate there should be a setting to chose the biome.

 

Biome:

There is no real biome system implemented yet. Historic bruno had some ideas about using it not only for random maps (I guess skirmish maps as well?).

In that case we should make chosing the biome a map setting.

 

Categorization:

Since maps like this (realistic terrain demo) are not always very fair IMO we should categorize maps optimized for multiplayer games and fairness that also should have about the same starting resources and large space for each player to build a base (and to allow the Iberian civ bonus walls to be placed without problems).

The other maps focussing more on realism or beauty should go into another category. For now this could just be "demo map" but in the long run I don't think that those maps likely more interesting in the long run should be categorized that way likely hidden for manny players and thus much less likely played.

However, the map size should be a setting thus not going into categorization. Same with the biome.

 

Library (some variables going to another library and the needed changes to the maps using this functionality allready):

RealisticTerrainDemo2016-1-31.zip

 

EDIT: Actually I would be glad if this would be added ASAP because it's interferring with the wall placement functionality in my working copy.

  • Like 2
Link to comment
Share on other sites

  • 2 months later...

Adjusted to be compatible to SVN r18013.

Changes:

- Removed random biome for realistic terrain demo (The random biome lib is not sufficient yet to be used here)

- Adjusted random biome for base terrain diamond square

- Diamond square heightmaps are now applied centered (so e.g. islands are not shifted any more on some map sizes)

RealisticTerrainDemo2016-04-10.zip

Link to comment
Share on other sites

11 minutes ago, FeXoR said:

- Diamond square heightmaps are now applied centered (so e.g. islands are not shifted any more on some map sizes)

Can we commit this change ASAP? It bugged Schwarzwald on certain map sizes on which a player could be placed on an island (because the lake wasn't properly centered)

Link to comment
Share on other sites

  • 1 month later...
  • 1 month later...

I will try to make this map playable enough to be added for Alpha 21 and am now in search of a name.

At the moment I'll go with Alpine Meadows.

Elexis thinks it looks more like scandinavia.

Any name suggestion welcome!

EDIT: It's about the random map untill now called Realistic Terrain Demo and that can be downloaded from the post above.

  • Like 1
Link to comment
Share on other sites

I worked a bit on it and the current version is: alpine_meadows2016-6-29.zip

I'm fine now with the overall design.

ToDo:

- Spots with fences and domesticated animals

- Enhance the expansion mines (small resource entities, bush actors, stone actors)

- Check over all steepness (enough flat ground for buildings?, most trees reachable?, ...)

- Check paths (Can an army walk on them when e.g. a narrow canion forms? Does they never fall below the water surface? ...)

- Check resource distribution (To many animals/bushes/fish? Are players in some maps nearly without access to wood? Low forests have no food, is that OK?)

- Add other fitting actors for beautification

- Chose final name and description

Any input very welcome! ;)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...