13.07.2011, 09:36
Hi can someone send me plugin for respawn all cars ? like this
if(strcmp(cmd, "/respawnallcars", true) == 0 || strcmp(cmd, "/rac", true) == 0)
{
if(PlayerInfo[playerid][pAdmin] <= 2000)
{
SendClientMessage(playerid, COLOR_GRAD1, "Vous n'кtes pas autorisez a utilisй cette commande!");
return 1;
}
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "[BC] Tous les vйhicules inutilisй ont йtй respawn par %s.", sendername);
SendClientMessageToAll(COLOR_WHITE,string);
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 <= MAX_VEHICULES; car++)
{
if(!unwanted[car]){SetVehicleToRespawn(car);}
}
return 1;
}
if(strcmp(cmd, "/respawnallcars", true) == 0 || strcmp(cmd, "/rac", true) == 0)
{
if(PlayerInfo[playerid][pAdmin] <= 2000)
{
SendClientMessage(playerid, COLOR_GRAD1, "Vous n'кtes pas autorisez a utilisй cette commande!");
return 1;
}
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "[BC] Tous les vйhicules inutilisй ont йtй respawn par %s.", sendername);
SendClientMessageToAll(COLOR_WHITE,string);
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 <= MAX_VEHICULES; car++)
{
if(!unwanted[car]){SetVehicleToRespawn(car);}
}
return 1;
}