captive: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
mNo edit summary
mNo edit summary
Line 25: Line 25:
'''Example:'''
'''Example:'''


? !('''captive''' [[player]]) : [[goto]] "run"
[[if]] ([[not]] '''captive''' [[player]]) [[then]] {[[goto]] "run"}





Revision as of 16:28, 21 May 2006


captive unit


Operand types:

unit: Object

Type of returned value:

Boolean

Description:

Check if unit is captive.

If unit is a vehicle, its commander is checked.


Example:

if (not captive player) then {goto "run"}


Comments:

Use setCaptive to make a unit captive.