Skip to content

WorldGen quick start

This guide gets streaming terrain running in an empty level. It assumes WorldGen is installed.

  1. Place the streaming manager. In the Place Actors panel, search for WorldStreamingManager and drag one into your level near the world origin.

  2. Assign a terrain material. Set WorldGen → Terrain Material to a material that reads WorldGen’s vertex colour and UV channels (see below).

  3. Preview in the editor. Click Preview Terrain in the Details panel. Terrain appears asynchronously within a second or two. Change parameters and click it again to rebuild.

  4. Play. Terrain streams around the player automatically, with no further setup.

WorldGen bakes all terrain blend weights into the mesh. Your material reads them to blend its layers.

Channel Material node Meaning
VertexColor.R Vertex Color → R Water: 1.0 below sea level, 0.0 above
VertexColor.G Vertex Color → G Grass: the base layer
VertexColor.B Vertex Color → B Rock: height and slope based
VertexColor.A Vertex Color → A Snow: high-altitude cap
UV1.R TextureCoordinate(1) → R Beach / sand: 1.0 at the waterline, fading above. Also carries desert sand.
UV1.G TextureCoordinate(1) → G Road: 1.0 at the road centreline, fading across the corridor

The manager also pushes a SeaLevelZ scalar parameter into the material.

Recommended blend order:

Grass (base)
→ Lerp(Grass, Rock, Alpha = VertexColor.B)
→ Lerp(above, Snow, Alpha = VertexColor.A)
→ Lerp(above, Beach/Sand, Alpha = TextureCoordinate(1).R)
→ Lerp(above, Road/Tarmac, Alpha = TextureCoordinate(1).G)
→ Lerp(above, Underwater, Alpha = underwater_mask)

For a smooth per-pixel underwater mask:

AbsoluteWorldPosition → Mask (B)
→ Subtract (SeaLevelZ)
→ Multiply (-1)
→ Divide (500)
→ Saturate
→ use as the Underwater Lerp alpha

Select the WorldStreamingManager, tick WorldGen → Biomes → Enable Spatial Biomes and click Preview Terrain. Temperature and humidity noise now divide the world into Tundra, Boreal, Desert and Tropical zones. Desert sand appears automatically, with no material changes.

  1. Create a WorldGenRoadAsset and a WorldGenSettlementAsset (Content Browser → Add → Miscellaneous → Data Asset), or use the included samples.

  2. On the manager, under WorldGen → Roads, assign both assets and tick Enable Roads.

  3. Assign a Road Mesh on the road asset and click Preview Terrain.

Settlements and the roads between them are generated from the seed, so the whole network is reproducible and seam-free.

  • Features covers the actor spawner, exclusion volumes, water and multiplayer.
  • Troubleshooting covers falling through terrain, navigation limits and building placement.