19.01.2015, 07:15
And use this SaveVehicle stock
You forgot to write IsValidVehicle(v)
If u don't do this then it will save 2000 vehicles in database with coords 0.0 0.0 0.0 and thus will load 2000 vehicles at those coords
And if there is any other command for creating vehicle or you create vehicle with AddStaticVehicle OnGameModeInit OR if u create vehicle using a FS then this system will bug, this system is only valid if u create cars using createveh command
pawn Code:
SaveVehicles()
{
for(new v = 0; v < MAX_VEHICLES; v++)if(IsValidVehicle(v)) SaveVehicle(v);
}
If u don't do this then it will save 2000 vehicles in database with coords 0.0 0.0 0.0 and thus will load 2000 vehicles at those coords
And if there is any other command for creating vehicle or you create vehicle with AddStaticVehicle OnGameModeInit OR if u create vehicle using a FS then this system will bug, this system is only valid if u create cars using createveh command