Arma 3 Scripting

Command in Turrets

setTurretLimits

Also available as Markdown and JSON, or read the original wiki page.

Description

Sets the rotation and elevation limits for the given turret. The limits are relative to model orientation of the turret. For example to allow 360 degree turning it is enough to set turn limits to (-180, 180). The limits can only be set within the limits defined in config and cannot exceed them. To reset to config defaults pass the turret argument only (Example 2).

Syntax

Syntax 1

vehicle setTurretLimits [turret, minTurn, maxTurn, minElev, maxElev, soft]

Parameters:

Returns: Nothing

Syntax 2

vehicle setTurretLimits [turret]

Parameters:

Syntax 3

Returns: Nothing

Examples

Example 1

m2 setTurretLimits [[0], -45, 45, -10, 10];

Example 2

m2 setTurretLimits [[0]]; //reset

Example 3

m2 setTurretLimits [[0], -45, 45, -10, 10, true];

See also

getTurretLimits · setTurretOpticsMode · turretLocal · selectWeaponTurret · lockCameraTo