[Ajuda] /setadmin bugado
#1

Код:
CMD:setadmin(playerid, params[])
{
    new iD, Level, gQuery[250], pName[24], gMessage[250], gVictim[24];
    if(PlayerInfo[playerid][pAdm] == 2)
    {
        if(sscanf(params, "ui", iD, Level)) return SendClientMessage(playerid, 0xFF0000FF, "* Use assim: /wayadmin [playerid] [lvl 1 a 3]");
        else if(iD == playerid) return SendClientMessage(playerid, 0xFF0000FF, "* Vc nao pode usar em vc mesmo ne");
        else if(!IsPlayerConnected(iD)) return SendClientMessage(playerid, 0xFF0000FF, "*ID NAO ENCONTRADO.");
        else
        {
            GetPlayerName(playerid, pName, sizeof(pName));
            GetPlayerName(iD, gVictim, sizeof(gVictim));
            format(gQuery, sizeof(gQuery), "UPDATE playerdata SET adm = '%i' WHERE user = '%s'", Level, pName);
            mysql_query(gQuery);

            format(gMessage, sizeof(gMessage), "* You have set %s an admin. Level: %i", gVictim, Level);
            SendClientMessage(playerid, 0xFFFFFFFF, gMessage);

            format(gMessage, sizeof(gMessage), "* Reinicie o Jogo para Carregar o ADM ou GM no seu Personagem.", Level);
            SendClientMessage(playerid, 0xFFFFFFFF, gMessage);

            PlayerInfo[iD][pAdm] = Level;
        }
    }
    else
    {
        SendClientMessage(playerid, 0xFF0000FF, "* Voce nao e ADM ou GM do servidor.");
    }
    return 1;
}
O comando sabe que sou admin sу que quando vou usar em alguma pessoa sу fala isso ID NAO ENCONTRADO

Por favor me ajudeee nao sei mais oq fazer ja pus outros comandos e da a mesma coisa
Reply


Messages In This Thread
/setadmin bugado - by djgabrielway - 06.04.2014, 03:26
Re: /setadmin bugado - by VeNuZ_ - 06.04.2014, 10:11
Re: /setadmin bugado - by djgabrielway - 06.04.2014, 21:24
Re: /setadmin bugado - by Douglas_prt - 06.04.2014, 21:30
Re: /setadmin bugado - by djgabrielway - 06.04.2014, 21:59
Re: /setadmin bugado - by Douglas_prt - 06.04.2014, 22:00
Re: /setadmin bugado - by djgabrielway - 06.04.2014, 22:04
Re: /setadmin bugado - by Douglas_prt - 06.04.2014, 22:09
Re: /setadmin bugado - by djgabrielway - 06.04.2014, 22:15
Re: /setadmin bugado - by djgabrielway - 10.04.2014, 06:19

Forum Jump:


Users browsing this thread: 1 Guest(s)