TerrainGeneration (user)

From OpenCity

Opencity have a built-in map generator, also allow loading from height-map.

Contents

Built-in generator

Usage: opencity {...} --generator-seed seed [--generator-map MAP-TYPE] [--generator-water WATER-TYPE]
[--generator-map-shape MAP-SHAPE-TYPE] [--generator-tree-density TREE-DENSITY-TYPE]

It generate a height-map post-processed by different kinds of re-sharper. Look at TerrainGeneration to see how it work.

Map type

0=plain (default)
1=hill
2=mountain

Set rough base map.

Map shape type

0=none (default)
1=island
2=volcano
3=crater

Re-shape the base map in order to look like.

Water type

0=dry
1=lake (default)
2=coast

Set water level.

Tree density type

0=sparse (default)
1=normal
2=dense

Generate a tree density (height-map), same thing as map type but for tree.

Height-map loader

Usage: opencity {...} [--generator-height-map heightMapPicture]

Load a gray-level picture as height map (PNG). The water level is gray level 128, each map level is one gray level. that's why the whole picture seems to be in a medium gray, because there's only a minor difference between the pixels. You can draw yourself the height-map or generate from any map sources. The interesting data for this work are the DEM satellite data. The map generator in OpenCity will crop the picture if it's too big.

Personal tools