Vehicle::getDriftTyresEnabled

From RAGE Multiplayer Wiki
Revision as of 17:06, 22 April 2024 by Shr0x (talk | contribs) (Created page with "{{JSContainer| === Required Arguments === *'''handle:''' Vehicle handle ===Return value=== *'''void''' ==Syntax== <syntaxhighlight lang="javascript"> mp.game.vehicle.getDriftTyresEnabled(handle); </syntaxhighlight> ==Example== <syntaxhighlight lang="javascript"> const vehicle = mp.vehicles.atRemoteId(0); //get vehicle with remote id 0 if (!vehicle || !mp.vehicles.exists(vehicle)) return; //if the vehicle don't exist we return here //Vehicle is valid, processing the...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

JavaScript Syntax


Required Arguments

  • handle: Vehicle handle

Return value

  • void

Syntax

mp.game.vehicle.getDriftTyresEnabled(handle);

Example

const vehicle = mp.vehicles.atRemoteId(0); //get vehicle with remote id 0
if (!vehicle || !mp.vehicles.exists(vehicle)) return; //if the vehicle don't exist we return here
//Vehicle is valid, processing the code:
const driftTyres = mp.game.vehicle.getDriftTyresEnabled(vehicle.handle);
mp.console.logWarning(`Vehicle ${driftTyres ? 'has' : 'does not have'} drift tyres enabled.`)


See also