vehicle: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
(sqf example; note about current arma 3 output)
(This is incorrect, vehicle player == player is always false if player is in driver seat)
Line 28: Line 28:
<dl class="command_description">
<dl class="command_description">
<!-- Note Section BEGIN -->
<!-- Note Section BEGIN -->
<dd class="notedate">Posted on February 16, 2014
<dt class="note">'''[[User:Strangepete|Strangepete]]'''
<dd class="note">As of Arma 3, ( vehicle unit == unit ) is TRUE for units in the vehicle's Driver seat, IF vehicle not named manually in Editor.
Example 2 will return TRUE if vehicle pre-named in Editor; Example 2 will return FALSE if vehicle not pre-named, and player in Driver seat
<!-- Note Section END -->
<!-- Note Section END -->
</dl>
</dl>

Revision as of 17:45, 16 February 2014

Hover & click on the images for description

Description

Description:
Vehicle in which given unit is mounted. If none, unit is returned.
Groups:
Uncategorised

Syntax

Syntax:
Object = vehicle unitName
Parameters:
unitName: Object
Return Value:
Object

Examples

Example 1:
SQS ? vehicle player != player : hint "Player is in a vehicle"
Example 2:
SQF (see Notes)if ( vehicle player != player ) then { hint "Player is in a vehicle"; };

Additional Information

See also:
See also needed

Notes

Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note

Notes

Bottom Section