Random Vehicle Spawn
#1

Hey guys

Is it possible to set random vehicle spawns for "CreateVehicle" as i done a car shop but its kinda useless if all cars spawn on top of each other.

I done it in a dialog based system but i attempted using

Quote:

new PoliceVeh = random(6);
switch (PoliceVeh)
{

case 0:

{
PoliceVeh[playerid] = CreateVehicle(523,-1581.8171,651.2495,6.9569,0.2016, -1, -1, -1);
PutPlayerInVehicle(playerid,RandomVeh(playerid), 0);
}

case 1:

{
PoliceVeh[playerid] = CreateVehicle(523,-1587.6960,651.1417,6.9563,359.9494, -1, -1, -1);
PutPlayerInVehicle(playerid,RandomVeh(playerid), 0);
}

case 2:

{
PoliceVeh[playerid] = CreateVehicle(523,-1594.2667,674.4127,6.9565,180.4530, -1, -1, -1);
PutPlayerInVehicle(playerid,RandomVeh(playerid), 0);
}....

Just got a load of errors anyone wanna help ?
Reply
#2

pawn Код:
new PoliceVeh[MAX_PLAYERS] = random(6);
switch (PoliceVeh[playerid])
try to change the 2 first lines to this... ^
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)