Arma 3 Scripting

Command in Object Manipulation, Unit Control

unassignVehicle

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

Description

Unassigns individual unit from a vehicle, usually previously assigned with assignAsXXX command, i.e removes assignedVehicleRole of the unit. If the unit is currently in that vehicle, the group leader will issue an order to disembark.

Note

See AI Group Vehicle Management for more information.

Syntax

unassignVehicle unitName

Parameters:

Returns: Nothing

Examples

Example 1

unassignVehicle player;

Example 2

Make all the occupants of a vehicle disembark:

{ unassignVehicle _x } forEach crew _vehicle;

Example 3

Make all the occupants of a vehicle disembark and unable to get back in:

private _crew = crew _vehicle;
{ unassignVehicle _x } forEach _crew;
_crew allowGetIn false;

See also

assignAsCargo · assignAsCommander · assignAsDriver · assignAsGunner · assignAsTurret · assignedVehicle · leaveVehicle · assignedVehicles · assignedGroup · fullCrew