Random colors for spawning vehicles
#1

Hello, I have a /turismo command. It spawns a Turismo vehicle if a player do the command. But how can I give the vehicle random colors, when it spawns its always white. But I want it in random colors. How can I do that?

Thanks!

Regards,

mickos
Reply
#2

You can use random function for the colours. An example:
pawn Код:
CreateVehicle(modelid, x, y, z, angle, random(255), random(255), 60);
Reply
#3

Set vehicle colors on -1, -1
Reply
#4

@Konst

Is there any difference between using -1 and what you suggested? I mean this in a genuinely curious way.
Reply
#5

Quote:
Originally Posted by PrivatioBoni
Посмотреть сообщение
@Konst

Is there any difference between using -1 and what you suggested? I mean this in a genuinely curious way.
Using -1 will cause to the color to be randomized there's no really difference from randoming it yourself or using -1.
Reply
#6

Using -1 will cause the vehicles to use the standard colors used in GTA SA, most vehicles will be random but taxi, police, firefighters, ... will only have one set of colors
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)