Car spawning checkpoint stops working randomly
#3

Hm, your code seems fine, there's only one thing I can think of though:
pawn Код:
NextCarSpawnerCar = NextCarSpawnerCar++;
//change to
NextCarSpawnerCar++;
https://sampwiki.blast.hk/wiki/Limits - as you can see here the vehicle limit is 2000 (MAX_VEHICLES)
Now - you are accessing CarSpawnerCar[NextCarSpawnerCar] - if the NextCarSpawnerCar gets over 1999 you will run into runtime error.

Oh, and this:
pawn Код:
CarSpawnerCar[NextCarSpawnerCar] = SetVehicleNumberPlate(CreateVehicle(492,2509.0259,-1665.4360,13.2234,35.5265,-1,-1,-1), "{00FF00}GROVE");
//change to
CarSpawnerCar[NextCarSpawnerCar] = CreateVehicle(492,2509.0259,-1665.4360,13.2234,35.5265,-1,-1,-1);
SetVehicleNumberPlate(CarSpawnerCar[NextCarSpawnerCar], "{00FF00}GROVE");
SetVehicleNumberPlate doesn't return a specific value, while createvehicle returns vehid.

I can't see any other issues that could cause this

Cheers
Reply


Messages In This Thread
Car spawning checkpoint stops working randomly - by Sydcul - 07.02.2013, 14:35
Re: Car spawning checkpoint stops working randomly - by Sydcul - 07.02.2013, 20:03
Re: Car spawning checkpoint stops working randomly - by Misiur - 07.02.2013, 20:26

Forum Jump:


Users browsing this thread: 2 Guest(s)