31.12.2013, 20:56
in your /destroycars cmd
just take the message out of the loop.
just do that:
after the loop's done.
Never use messages in a loop unless you want to spam something :P
the /destroycars cmd should look like this,
just take the message out of the loop.
just do that:
PHP код:
new string[128];
format(string, sizeof(string), "{FF0000}[Admin Warn]{FF6347} %s has destroyed all Created vehicles (/veh)icle.", NORPN(playerid));
SendAdminMessage(COLOR_DARKRED, 1, string);
Never use messages in a loop unless you want to spam something :P
the /destroycars cmd should look like this,
PHP код:
CMD:destroycars(playerid, params[])
{
if(PlayerInfo[playerid][pAdmin] < 2) return SendClientMessage(playerid, COLOR_GREY, "You are not authorized to use that command!");
new string[103];
for(new i = 0; i < sizeof(cVeh); i++)
{
if(cVeh[i] == INVALID_VEHICLE_ID) continue;
DestroyVehicle(cVeh[i]);
cVeh[i] = -1;
}
format(string, sizeof(string), "{FF0000}[Admin Warn]{FF6347} %s has destroyed all Created vehicles (/veh)icle.", NORPN(playerid));
SendAdminMessage(COLOR_DARKRED, 1, string);
SendClientMessage(playerid, COLOR_GREY, " Created vehicles destroyed!");
return 1;
}

