03.03.2013, 11:34
how can i make IsATrailer and IsATL not to /rac i dont want them to respawn plz help!
PHP код:
if(strcmp(cmd, "/respawnallcars", true) == 0 || strcmp(cmd, "/rac", true) == 0) //
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo[playerid][pAdmin] < 1337)
{
SendClientMessage(playerid, COLOR_GRAD1, " you are not authorized to use that command!");
return 1;
}
new bool:unwanted[CAR_AMOUNT];
for(new player=0; player<MAX_PLAYERS; player++)
{
if(IsPlayerInAnyVehicle(player)
{
unwanted[GetPlayerVehicleID(player)]=true;
}
}
for(new car = 1; car <= 359; car++ || IsATLCar(car) && IsATrailer(car))
{
if(!unwanted[car]) SetVehicleToRespawn(car);
}
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), " Toate vehicule sau respawnat de %s.", sendername);
BroadCast(COLOR_WHITE,string);
}
return 1;
}