Overview
The Deform component allows you to deform the terrain along the length of a spline.
This can have a variety of uses, such creating a raised road, a berm, a ditch, or a river bed.
Adding a Terrain Deform to a Spline
To add a Deform component to a spline, perform the following steps.
- In the Object Browser, find the Deform entity.
- Left-Click on the Deform entity and Drag it onto the Render view.
- A new Spline will be created with the Deform component attached. You may now modify the spline to create your desired effect.
When created, the deform will appear in the Scenario Tree, resembling the example below.
In this example, a texture has also been added to the deform.
Modifying your Deform
There are two main ways to modify the deform to create a deform effect:
- By modifying the Profile property of the deform
- By modifying the Weight Profile of the deform.
Editor
- Comment: Allows you to add a comment. Visible to anyone working in the editor.
- Display Name: A custom name you can add to this strip component for easy tracking/finding in the Scenario Tree.
- Exclude From Game: If checked, the strip component will not appear in the game (it will be hidden).
- Locked: If checked, the component cannot be edited.
- Visible: If checked, the strip component is can be seen in editor.
Control Points
- Sample Height: when checked it will sample the height of the terrain
Deform
- Layer Mode: Allows you to set how your deform's height will be combined with other heights.
- Sum - Adds the deform to the current ground, if other deforms, they are added on top.
- Min Max - Sets a fixed height from the lower point of the map.
- Set - Keeps the min or the max of combined shapes.
- Profile: See below for more info.
- Weight Profile: See below for more info.
Spline
- Width - Sets the width of the deform effect.
Using the Deform Profile
There are a few key properties that affect how a terrain deform spline looks and behaves.
To modify the properties of a spline using the Deform Profile controls, follow the steps below:
- In the Scenario Tree, select the Deform Component in your spline.
- In the Properties panel, set the Width of the spline.
By default, the deform component has a width of 5. You can increase this value to make the deform effect wider, or reduce it to make it thinner. - Once your width has been set, press Edit beside the the Profile setting.
The Time Varying panel will open, allowing you to edit the specifics of the deform.
If your Layer Mode is set to "Sum" you must also enter a value to define the height. - You are now ready to adjust the profile of the deform. See Editing the Height Profile below.
Example of Deform Profile
In the example below, the width is set to 9 so the deformation goes past the standard 5 set for the road texture. In addition, "0" has been added to the end point to make the road blend more smoothly with surrounding terrain at the sides.
Note if there is no defined height in the Height field, no deform will occur.
Editing the Height Profile
Press Edit Profile in the properties window to open the Time Varying panel for a spline.
By default there are two points in the Time Varying window which are both set to 1, which represents 100% of the height possible on a spline, with lesser values representing lower points.
In the example below, the spline in the Time Varying profile has 10 points to create a high road with ditches on the sides.
In the example below, the rocky ditch possesses the listed values.
The Weight Profile
The Weight Deform profile is used to straighten roads on a slope and to create ramps.
When adjusting the weight profile on a spline, it is important to keep the following points in mind:
- To create a smooth road on a hill, he Spline Width should be set to something wide, such as 20-30.
- Setting the Layer Mode to Set will cause the road to have a flatter surface.
- To further smooth the road, assure the Points in the splines have a natural gradiaent.
- To follow the elevation of the slope, assure the Sample Height is On.
- Weight Profile Edits are shown in the Time Varying section. The points along the road are set to 1 (flat) and edges of the profile are set to 0 to blend to the terrain on the edges.
- Adding only points to the Ends of the spline will create a ramp.
- Adding points to the Center of the spline will sample the height at the points to have a different look.