|
Returns
|
none
|
|
Prototype
|
Vehicle:SetColors(Color color1, Color color2)
|
|
Description
|
Sets a vehicle's colors immediately.
|
Examples
function PlayerChat(e)
if e.text == "/random" and e.player:InVehicle() then
local color = Color.FromHSV(
math.random( 0, 360 ),
math.random() * 0.2 + 0.5,
math.random() * 0.2 + 0.5 )
e.player:GetVehicle():SetColors( color, color )
end
end
Events:Subscribe( "PlayerChat", PlayerChat )
Additional Notes
- Each color corresponds to a different tone
- Vehicles in Just Cause 2 use a two-tone system for colors which can be used to emulate effects such as pearlescent coating.