Skip to main content

Condition_IsInVehicle

Description

This condition function determines whether the specified BaseObject (character) is currently riding in a vehicle. Optionally, a specific vehicle type can be specified using the S1 parameter.

The evaluation result is compared against the given CompareType:

  • Equal : Condition is true if the character IS in a vehicle.
  • NotEqual : Condition is true if the character is NOT in a vehicle.

Parameters

ParameterDescription
BaseObjectSpecifies the object to validate (Self or Target).
CompareTypeType of comparison operation (Equal or NotEqual).
S1(Optional) The vehicle type to check (Car, Motorcycle, Ship).

Examples

DescriptionBaseObjectCommandCompareTypeS1
Is self in any vehicle?SelfIsInVehicleEqual
Is self in a car?SelfIsInVehicleEqualCar
Is self not riding a motorcycle?SelfIsInVehicleNotEqualMotorcycle