Skip to end of metadata
Go to start of metadata


The following tutorial will show you how to setup a new level and its initial terrain map.
Terrain elevation in the Sandbox Editor is based on the brightness values of the height map textures that have been assigned to the terrain geometry.

Creating a New Level Folder and File


Do not use spaces or non-Alphanumeric characters in your level name. Underscores can be used instead of spaces.

Example: my_level instead of my level

Go to File -> New -> Level.

Choose where you'd like to save your level file, preferably the folder Levels in the project's Asset directory, before giving it a name in the New asset name field at the bottom.

Clicking OK opens another window where you can adjust the Heightmap Resolution and the Meters per Unit values according to the size and and detail you require, - for now let's leave everything as it is. Finally, click OK.

We do not recommended having a total terrain size that is greater than 4096x4096. Also, using a lower Meters per Unit value gives more precision in the terrain details and lowering the Heightmap Resolution will decrease memory consumption.

Adding Terrain to the Level

Generating Terrain

We now need to add some terrain - there are three main ways to do this;

  1. Have sandbox automatically generate a heightmap
  2. Sculpt manually
  3. Import a heightmap

Refer to our Beginner's Guide for an introduction to manually sculpting terrain and importing external heightmaps.

Generating Terrain Automatically

Go to the Terrain Editor tab (right side panel). Choose File -> Generate Terrain, the following dialog box will open:

Clicking OK will then generate a randomized map automatically.

The various parameters in the Generation dialog box can be used to influence the appearance of the terrain - the parameters are described below:



Feature Size

Determines the amount of land created

Bumpiness / Noise (Fade)

Determines the degree of bumpiness or deformation of the surface

Detail (Passes)

Determines the number of times that effects will be applied

Variation (Random Base)

Determines the random seeding of the islands.

Blurring (Blur Passes)

Sets the number of times that smoothing will be applied to the noise filter

Cover (Exp. Substract)


Sharpness (Exp. Base)

Determines the sharpness of the surface

Sharpness (Freq. Step)

Determines the number of times that the sharpness filter will be used on the surface

The terrain generated will look something like that in the screenshot below:

This is of course quite an unnatural looking terrain and requires some modification to make it look more realistic. To do this we must adjust the terrain max height.

Setting Terrain Max Height

In the terrain generated the XY dimensions of the level are correct (we set them to 1024x1024). However, the Z value is far too high.

To transform this into a more usable heightmap go to the Terrain Editor -> Edit -> Set Terrain Max Height.

Give it a lower value i.e. lower than the 1024 we set for the X and Y dimensions, let's set it at 320. The top of the terrain will now be flattened off.

Now generate the terrain again Terrain Editor -> File -> Generate Terrain. You'll notice that we have lost the huge sheer drop cliff faces (screenshot above) and acquired a much more realistic looking landscape. This is because the height is now set to a more reasonable value. The outcome will be different every time, because it's randomly generated, but you'll definitely see an improvement in the height of the terrain:

Generating Surface Texture

Now that we have a terrain we need to make it look more realistic by adding elements such as grass, mud, sand, rocks etc. For more information on how to add these elements, refer to our Beginner's Guide.

On This Page

Resizing the Terrain

Open the terrain resize window by going to Edit - Resize Terrain.

Here, you can change the heightmap of the level by modifying the Heightmap Resolution setting and Meters Per Unit setting.

Meters Per Unit represents the distance between two vertices (lying on a perpendicular grid) in meters. Adjusting the Meters Per Unit will change the size of the heightmap.

Changing the Meters Per Unit to 1 will make the terrain more detailed and changing to a higher value will make the terrain less detailed allowing you to create a bigger level with the same base heightmap resolution.

The default setting of 2 means that every 2 meters there is a new point.

The resize operation should be seen more as a canvas size operation not a scale operation, so if you reduce the size of you map, your map will be cropped to the new dimensions starting from 0,0 on the grid. 
When using this option only the terrain is changed, and objects and vegetation must either be deleted or moved to the new location.

After selecting the desired Heightmap and Meters Per Unit, click OK, and then select the texture dimensions.

  • No labels