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
| Parameter | Description |
|---|---|
| BaseObject | Specifies the object to validate (Self or Target). |
| CompareType | Type of comparison operation (Equal or NotEqual). |
| S1 | (Optional) The vehicle type to check (Car, Motorcycle, Ship). |
Examples
| Description | BaseObject | Command | CompareType | S1 |
|---|---|---|---|---|
| Is self in any vehicle? | Self | IsInVehicle | Equal | |
| Is self in a car? | Self | IsInVehicle | Equal | Car |
| Is self not riding a motorcycle? | Self | IsInVehicle | NotEqual | Motorcycle |