[Ajuda] Comando /daradmin
#10

tente assim agora acho que vai

Код:
 if(strcmp(cmd, "/daradmin", true) == 0) 
    { 
     if (PlayerInfo[playerid][pAdmin] >= 5000 || IsPlayerAdmin(playerid)) 
        { 
            if(IsPlayerConnected(playerid)) 
            { 
                tmp = strtok(cmdtext, idx); 
                if(!strlen(tmp)) 
                { 
                    SendClientMessage(playerid, COLOR_GRAD2, "USO: /daradmin [playerid/Parte-do-Nick] [level(1-5000)]"); 
                    return 1; 
                } 
                new para1; 
                new level; 
                para1 = ReturnUser(tmp); 
                tmp = strtok(cmdtext, idx); 
                level = strval(tmp); 
                { 
                    if(IsPlayerConnected(para1)) 
                    { 
                        if(para1 != INVALID_PLAYER_ID) 
                        { 
                            GetPlayerName(para1, giveplayer, sizeof(giveplayer)); 
                            GetPlayerName(playerid, sendername, sizeof(sendername)); 
                            PlayerInfo[para1][pAdmin] = level; 
                            printf("|ADMIN|: %s promoveu %s para administrador no nivel %d.", sendername, giveplayer, level); 
                            format(string, sizeof(string), "Vocк foi promovido a moderador, no nнvel %d pelo administrador %s.", level, sendername); 
                            SendClientMessage(para1, COLOR_LIGHTBLUE, string); 
                            format(string, sizeof(string), "Vocк promoveu %s com nнvel %d.", giveplayer,level); 
                            SendClientMessage(playerid, COLOR_LIGHTBLUE, string); 
                        } 
                    } 
                } 
                    else 
                { 
                    SendClientMessage(playerid, COLOR_GRAD1, "   Vocк nгo pode usar esse comando!"); 
                } 
            } 
            return 1; 
        } 
    }
Espero ter ajudado se poder da reputaзao agradeзo '-'
Reply


Messages In This Thread
Comando /daradmin - by LeonardoBCF - 27.03.2013, 20:02
Re: Comando /daradmin - by FlaaSShh - 27.03.2013, 20:04
Re: Comando /daradmin - by LeonardoBCF - 27.03.2013, 21:34
Re: Comando /daradmin - by Flash92 - 27.03.2013, 23:20
Re: Comando /daradmin - by LeonardoBCF - 28.03.2013, 00:35
Re: Comando /daradmin - by Flash92 - 29.03.2013, 01:07
Re: Comando /daradmin - by LeonardoBCF - 29.03.2013, 02:42
Re: Comando /daradmin - by Flash92 - 13.04.2013, 00:33
Re: Comando /daradmin - by bruxo00 - 13.04.2013, 09:05
Re: Comando /daradmin - by Smoking_Script - 13.04.2013, 11:07

Forum Jump:


Users browsing this thread: 1 Guest(s)