01.10.2012, 20:39
(
Последний раз редактировалось Dizzle; 02.10.2012 в 12:38.
)
Код:
CMD:respawnallveh(playerid, params[]) { #pragma unused params if(IsPlayerAdmin(playerid)) { SendClientMessage(playerid, -1, "All unoccupied vehicles were respawned!"); } for(new cars=0; cars<MAX_VEHICLES; cars++) { if(!VehicleOccupied(cars)) { SetVehicleToRespawn(cars); } } return 1; }
Код:
stock IsVehicleOccupied(vehicleid) { for (new i = 0; i < GetMaxPlayers(); i ++) { if (GetPlayerVehicleID(playerid) == vehicleid) return true; } return false; }