Returns information about seats in a vehicle. Note: multi-passenger mounts appear as vehicles for passengers but not for the owner; seat information applies only to the passenger seats.
See also Vehicle functions.
Signature:
controlType,
occupantName,
occupantRealm,
canEject,
canSwitchSeats
=
UnitVehicleSeatInfo("unit",
seat)
Arguments:
unit
- A unit to query (string
, unitID)seat
- Index of a seat in the unit's vehicle (number
)
Returns:
controlType
- Type of control for the seat (string
)Child
- Unit in this seat controls part of the vehicle but not its movement (e.g. a gun turret)None
- Unit in this seat has no control over the vehicleRoot
- Unit in this seat controls the movement of the vehicle
occupantName
- Name of the unit in the seat, or nil if the seat is empty (string
)occupantRealm
- Home realm of the unit in the seat; nil if the seat is empty or its occupant is from the same realm as the player (string
)canEject
- True if the vehicle's driver can eject the occupant of the seat (boolean
)canSwitchSeats
- True if the player can switch to this seat. (boolean
)