Quote:
Originally Posted by ginger
pawn Код:
new car[3]; new bool:check[3]; for(new i; i < 3; ++i) { for(new x; x < 3; ++x) { new file[26]; format(file, sizeof file, "carfile%i", x); if(fexist(file)) { if(!check[x]) { car[i] = CreateVehicle(...); check[x] = true; continue; } } } }
This will skip the id of the non existing file and turn to the existing one. I am helping you on phone though.
|
That's not the issue I am having I can skip them non-existing vehicles but if there are 3 vehicle or more and the number two vehicle was removed then they were re-loaded. When a vehicle creates ingame id will be 2. But the variables will be loaded in 3 not 2.