Question regarding %
#3

Quote:
Originally Posted by Donya
Посмотреть сообщение
pawn Код:
CMD:respawnveh(playerid, params[])
{
    #pragma unused params
    if(PlayerInfo[playerid][Admin] < 3) return SendClientMessage( playerid, COLOR_RED, "[ERROR]:You are not a Public Safety Member! Or your PSM level is too low!" );
    new bool:VehicleUsed[MAX_VEHICLES] = false, str[128] = "\0", pName[MAX_PLAYER_NAME];
    foreach(Character, i)//for(new i = 0; i < MAX_PLAYERS; i++)
    {
        if(IsPlayerInAnyVehicle(i)) VehicleUsed[GetPlayerVehicleID(i)] = true;
    }
    for(new i = 1; i < MAX_VEHICLES; i++)
    {
        if(VehicleUsed[i] == false) SetVehicleToRespawn(i);
    }
    GetPlayerName(playerid, pName, MAX_PLAYER_NAME);
    format(str, sizeof(str), "All unccupied vehicles have been respawned by %s(%d)", pName, playerid); //newly added
    SendClientMessageToAll(-1, str);
    return;
}
Could you please explain to me how it is done? :\
Reply


Messages In This Thread
Question regarding % - by Tachibana - 24.06.2011, 00:00
Re: Question regarding % - by Donya - 24.06.2011, 00:08
Re: Question regarding % - by Tachibana - 24.06.2011, 00:12
Re: Question regarding % - by StreetGT - 24.06.2011, 00:16
Re: Question regarding % - by Tachibana - 24.06.2011, 00:21

Forum Jump:


Users browsing this thread: 1 Guest(s)