[AJUDA]Respawn Veiculos Naum Ultilizados
#3

pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
    if (strcmp("/resetnonused", cmdtext, true, 10) == 0)
    {
        if(!IsPlayerAdmin(playerid)) SendClientMessage(playerid,-1,"Vocк nгo esta logado na Rcon");
        for(new i = 0; i < MAX_VEHICLES; ++i)
        {
            if(!IsVehicleOccupied(i))
            {
                SetVehicleToRespawn(i);
            }
        }
    }
    return 0;
}
pawn Код:
stock IsVehicleOccupied(vehicleid)
{
    for(new i = 0; i < MAX_PLAYERS; i++)
    if(IsPlayerInVehicle(i, vehicleid) && GetPlayerState(i) == PLAYER_STATE_DRIVER)
    return 1;
    return 0;
}
Reply


Messages In This Thread
[AJUDA]Respawn Veiculos Naum Ultilizados - by [BC]Pegador[KoF] - 20.11.2011, 21:38
Re: [AJUDA]Respawn Veiculos Naum Ultilizados - by Cristhian - 20.11.2011, 21:41
Re: [AJUDA]Respawn Veiculos Naum Ultilizados - by TiagoPS - 20.11.2011, 21:45
Re: [AJUDA]Respawn Veiculos Naum Ultilizados - by Pharrel - 20.11.2011, 21:48
Re: [AJUDA]Respawn Veiculos Naum Ultilizados - by Cristhian - 20.11.2011, 21:51

Forum Jump:


Users browsing this thread: 1 Guest(s)