[Ajuda] gangzoni
#7

Ficou desse modo:

pawn Код:
new PlayerDominating[MAX_PLAYERS char];

CMD:dominar(playerid,params[])
{
    if(!IsAreaInGangCheck(playerid)) return SendClientMessage(playerid,red,"-Erro- Vocк nгo estб em uma gangzone!");
    new Float:x, Float:y, Float:z;
    GetPlayerPos(playerid, x, y, z);
    for(new i = 0; i < GZS_CRIADAS; i++)
    {
        if(x > CordGZs[i][0] && y > CordGZs[i][1] && x < CordGZs[i][2] && y < CordGZs[i][3]&& z < 500)
        {
            GangZoneFlashForAll(GZCriadas[i],GetPlayerColor(playerid));
            PlayerDominating{playerid} = i;
        }
    }
    for(new i, e = GetMaxPlayers(); i != e; ++i)
    {
        if(IsPlayerConnected(i))
        {
            if(i != playerid)
            {
                if(PlayerDominating{playerid} == PlayerDominating{i})
                {
                    SendClientMessage(playerid, red, "-Erro- Jб esxiste uma gangue(ou sua gangue) dominando estб gangzone");
                    PlayerDominating{playerid} = -1;
                    return 0;
                }
            }
        }
    }
    SendClientMessage(playerid,green,"Dominando... aguarde 2 minutos na бrea.");
    SetTimerEx("Terminar",5000,false,"d",playerid);
    return 1;
}

public Terminar(playerid)
{
    if(!IsAreaInGangCheck(playerid))
    {
        SendClientMessage(playerid,red,"-Erro- Vocк nгo consegui domninar a gangzone, pois vocк saiu dela!");
    }
    new Float:x, Float:y, Float:z;
    GetPlayerPos(playerid, x, y, z);
    for(new i=0; i < GZS_CRIADAS; i++)
    if(x > CordGZs[i][0] && y > CordGZs[i][1] && x < CordGZs[i][2] && y < CordGZs[i][3]&& z < 500)
    {
        GangZoneStopFlashForAll(GZCriadas[i]);
    }
    PlayerDominating{playerid} = -1;
    return 1;
}
Mais consigo digitar o comando vбrias vezes.. e quando acaba de dominar nгo seta a cor da GZ para cor do player.. Help-me?
Reply


Messages In This Thread
gangzoni - by s4kuL - 12.09.2012, 23:29
Re: gangzoni - by focaximubh - 13.09.2012, 01:11
Re: gangzoni - by s4kuL - 13.09.2012, 02:20
Re: gangzoni - by zSuYaNw - 13.09.2012, 04:35
Re: gangzoni - by s4kuL - 13.09.2012, 14:58
Re: gangzoni - by zSuYaNw - 13.09.2012, 19:13
Re: gangzoni - by s4kuL - 13.09.2012, 21:09
Re: gangzoni - by s4kuL - 14.09.2012, 00:20
Re: gangzoni - by zSuYaNw - 14.09.2012, 03:23
Re: gangzoni - by s4kuL - 14.09.2012, 15:19

Forum Jump:


Users browsing this thread: 1 Guest(s)