Vehicle::getColor

From RAGE Multiplayer Wiki
Revision as of 17:46, 16 August 2018 by Stuyk (talk | contribs) (→‎Example)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Syntax

vehicle.getColor(id);

Required Arguments

  • id: int

(0 - Primary Color, 1 - Secondary Color)

Return value

  • integer: color

Example

let primaryColor = player.vehicle.getColor(0)
let secondaryColor = player.vehicle.getColor(1)

// If the vehicle primary color was black the following would return 0
console.log(primaryColor)

See also