Page tree
Skip to end of metadata
Go to start of metadata

This command / function is broken and / or unreliable in VBS4.

Introduced in



Description:Adjusts the slope (and position) of the object to follow the underlying terrain contour.


Syntax:placeOnSurface object
  • object: Object - Object to align / move. The object is only aligned with the surfaceNormal, but not moved vertically, to be on top of that surface (to do so, use the Alternative Syntax).
Return Value:Nothing

Alternative Syntax

Syntax:placeOnSurface [object, move, considerSnow, smartPlacing] (V3.3+)
  • object: Object - Object to align / move.
  • move: Boolean - If true, then the object is placed on top of the underlying terrain.
  • considerSnow: Boolean - If true, then the alignment takes into account any slopes created by snow layers.
  • smartPlacing: Boolean - If true, the orientation is determined based on the terrain below the land contact points, and the object is elevated to avoid collision with the surface (including water) (optional, default: false(V20.2+).
Return Value:Nothing


placeOnSurface tank1;
placeOnSurface [tank1, true, true];
placeOnSurface [tank1, true, true, true]; // attempt to avoid any collision with surface

Additional Information

See also:fn vbs placeOnSurface
Problems:Placement (using alternative syntax) on elevated roadways (for example, bridges, rooftops) may not be applied correctly.


The smartPlacing parameter is more computationally expensive, but helps placing larger vehicles, which might get placed under the terrain with regular placement (when smartPlacing is not used).