How to change a car's color?

Started by NicusorN5, Apr 26, 2016, 02:11 PM

Previous topic - Next topic

NicusorN5

What is the function to change a created car color? `

KingOfVC

Vehicle.Colour1
Vehicle.Colour2

Cool

you have your vehicles in database

MaTaDeToR

#3
Quote from: NicusorN5 on Apr 26, 2016, 02:11 PMWhat is the function to change a created car color? `
if ( cmd =="changecolor")
                       {
                          if ( player.Vehicle )
                                  {
                                  local Color = rand() % 94;
                                  ClientMessage("Your Vehicle color has been changed randomly",player,255,255,0);
                                             player.Vehicle.Colour1 = Color;
                                                    }
                                 else ClientMessage("You need to be inside a vehicle to use this command",player,255,255,0);
                  }
Well, i've given this Code before, it's simply the Vehicle.Color1 function could be found at Wiki as well; therefore, Vehicle.Color2 as the another function to change the second custom color of Car.

NicusorN5


RW

vehicle.Colour1 = <Colour ID>
vehicle.Colour2 = <Colour ID>
Maybe it can help you :D

KAKAN

Quote from: [F.B.I]RW on Apr 27, 2016, 10:58 AMvehicle.Colour1 = <Colour ID>
vehicle.Colour2 = <Colour ID>
Maybe it can help you :D
Read the posts. It's already posted above with a good example, which can help you too.
oh no

Thijn

Locked. Answer has been given.