Road construction

In this recipe, we will explore the basic uses of the Road tool and how to paint down paths that are easy for the player to recognize.

Getting ready

  • Before we begin, you must have Sandbox 3 open
  • Then open My_Level.cry

How to do it...

  1. From the RollupBar, open the Objects tab.
  2. Select the Misc button.
  3. From the Object Type, select Road.
  4. Make sure you are set to Align to Terrain.
  5. Click down three points in roughly a straight line.
  6. Double-click for the fourth point to finalize the road.
  7. Open the Material Editor (M).
  8. Assign the material materials | Terrain | roads | road_asphalt01 to the road.
    How to do it...

How it works...

The Road tool is a spline that projects a repeating texture along the terrain surface.

There's more...

The following are some of the definitions to the parameters for the road as well as how you can edit the shape of the road.

Road parameters

  • Width: This is the width of the road in meters.
  • StepSize: This affects the tiling amount on the road. It is used for both the texture and the curves on the road.
  • TileLength: This affects the stretching amount in just the road texture.
  • SortPriority: This determines the priority of which projected texture should be displayed on top (Decals match this priority range).

Shape editing

You may make modifications to any pre-existing road by selecting it and turning on Edit from the Shape Editing menu item. The Road tool's spline is affected by where the points are situated between each other. From the X and Y locations of the points, curves are automatically created and projected against the ground. The Z axis makes little difference in the way the road is projected onto the terrain; however, it is still a good practice to maintain the road spline above and close to the terrain surface.

  • Adding Points: Ctrl + click to add additional points.
  • Angle: You may change the angle at which the projection of the road is casted. The angles range from -25 to +25.
  • Individual Point Width: Turning off the Default width option will enable you to adjust the width of the individual points on the road.

Align Height Map

This tool is extremely useful for any designer who wishes to quickly align his/her height map to the Z locations on the road. This is also an excellent method for making ramps.

See also

  • The Terrain Sculpting recipe in Chapter 2,Sandbox Basics
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
13.59.107.152