Can't RESPAWN filterscript's cars with /rac
#5

Try with this:
Quote:

if(!strcmp(cmd, "/respawnallcars", true) || !strcmp(cmd, "/rac", true))
{
if(Player[playerid][piAdminRank] >= RANK_STAFF_GA)
{
new bool:unwanted[MAXIMUM_VEHICLES];
for(new P = 0; P < MAX_PLAYERS; P ++)
{
if(IsPlayerInAnyVehicle(P)) unwanted[GetPlayerVehicleID(P)] = true;
}
for(new V = 0; V < MAX_VEHICLES; V ++)
{
if(!unwanted[V])
{
SetVehicleToRespawn(Vehicle1);
SetVehicleToRespawn(Vehicle2);
SetVehicleToRespawn(Vehicle3);
SetVehicleToRespawn(Vehicle4);
SetVehicleToRespawn(Vehicle5);
SetVehicleToRespawn(Vehicle6);
SetVehicleToRespawn(Vehicle7);
SetVehicleToRespawn(Vehicle8);
SetVehicleToRespawn(Vehicle9);
}
if(CarInfo[V][tOwned] && CarInfo[V][tLicensePlate])
{
new plate[10];
strmid(plate, CarInfo[V][tLicensePlate], 0, strlen(CarInfo[V][tLicensePlate]), 255);
SetVehicleNumberPlate(V, plate);
}
}
format(string, sizeof(string), "INFO: All unoccupied vehicles respawned by %s.", ReturnPlayerName(playerid, false));
SendClientMessageToAll(COLOR_LIGHTRED, string);
}
else
{
SendClientMessage(playerid, COLOR_GREY, " You are not authorized to use this command.");
}
return 1;
}

I dont know if that is the function you want to get, if it doesnt, please describe more what you want to do.
Reply


Messages In This Thread
Can't RESPAWN filterscript's cars with /rac - by AlexSkyrise - 08.05.2013, 14:27
Re: Can't RESPAWN filterscript's cars with /rac - by vvhy - 08.05.2013, 14:40
Respuesta: Can't RESPAWN filterscript's cars with /rac - by LoLeRo - 08.05.2013, 14:40
Re: Can't RESPAWN filterscript's cars with /rac - by AlexSkyrise - 08.05.2013, 15:08
Respuesta: Can't RESPAWN filterscript's cars with /rac - by LoLeRo - 08.05.2013, 20:56
Re: Can't RESPAWN filterscript's cars with /rac - by AlexSkyrise - 09.05.2013, 06:17
Respuesta: Can't RESPAWN filterscript's cars with /rac - by LoLeRo - 09.05.2013, 20:02

Forum Jump:


Users browsing this thread: 1 Guest(s)