[Ajuda] Me ajudem a passar pra dialogo?
#1

Olhe esse comando..
pawn Код:
if(!strcmp(cmdtext, "/admins", true))
{
SendClientMessage(playerid,0x00FF40AA, ".:: - Administradores Online - ::.");
new count=0;
for(new i=0; i<MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i)){
if(admin[i]){
new str[256];
new pname[24];
GetPlayerName(i, pname, 24);
format(file2, sizeof(file2), PASTA_CONTAS, pname);
if(pAdmin[i] == 1){
format(str,sizeof(str),"%s (%d) :: {3225EB}[Helper]", pname,i);
}
if(pAdmin[i] == 2){
format(str,sizeof(str),"%s (%d) :: {3225EB}[Adminstrador]", pname,i);
}
if(pAdmin[i] == 3){
format(str,sizeof(str),"%s (%d) :: {3225EB}[Administrador Chefe]", pname,i);
}
if(pAdmin[i] == 4){
format(str,sizeof(str),"%s (%d) ::{3225EB} [Sub Dono]", pname,i);
}
if(pAdmin[i] == 5){
format(str,sizeof(str),"%s (%d) :: {3225EB}[Dono]", pname,i);
}
SendClientMessage(playerid, 0x0080FFAA, str);
count++;
}
}
}
if(count == 0)
{
SendClientMessage(playerid, Vermelho, "(ERRO) Nгo hб administradores online no momento");
}
return 1;
}
Tem como vocкs me ajudarem a passar ele para aparecer no dialogo?
Obrigado.
Reply
#2

Nгo sei porque vc quer entregar o nome dos admins de mгo beijada aos cheaters. Mas Ok...
Reply
#3

Quote:
Originally Posted by TreePuncher
Посмотреть сообщение
Nгo sei porque vc quer entregar o nome dos admins de mгo beijada aos cheaters. Mas Ok...
Nem eu auheuae, mais consegue me ajudar?
Reply
#4

tome:

https://sampforum.blast.hk/showthread.php?tid=280287
https://sampforum.blast.hk/showthread.php?tid=369629
https://sampforum.blast.hk/showthread.php?tid=340348
https://sampforum.blast.hk/showthread.php?tid=319196
https://sampforum.blast.hk/showthread.php?tid=162971

isos pode lhe ajudar!
Reply
#5

Tenta esse meu amigo

Код:
if (strcmp(cmd, "/admins", true) == 0)
	{
	    new DialogKevin[1500];
		//SendClientMessage(playerid, COLOR_WHITE, "|__________________[ Admins Online ]__________________|");
		for(new i = 0; i <= MAX_PLAYERS; i++)
		{
			if(IsPlayerConnected(i) == 1 && PlayerInfo[i][pAdmin] > 0)
			{
				if(admhide[i] == 0)
				{
					GetPlayerName(i, sendername, sizeof(sendername));
					new lolz[20];
				    if(PlayerInfo[i][pAdmin] == 1)
				    {
						lolz = "Moderador";
					}
					if(PlayerInfo[i][pAdmin] == 2)
				    {
						lolz = "Admin_Novato";
					}
					if(PlayerInfo[i][pAdmin] == 3)
				    {
						lolz = "Administrador";
					}
					if(PlayerInfo[i][pAdmin] == 4)
				    {
						lolz = "Sub_Master";
					}
					if(PlayerInfo[i][pAdmin] == MASTER)
				    {
						lolz = "Master";
					}
					if(PlayerInfo[i][pAdmin] == SUB_GERENTE)
				    {
						lolz = "Master++";
					}
					if(PlayerInfo[i][pAdmin] == GERENTE)
				    {
						lolz = "Sub_Dono";
					}
					if(PlayerInfo[i][pAdmin] == SUB_DONO)
				    {
						lolz = "Dono";
					}
					if(PlayerInfo[i][pAdmin] == DONO)
				    {
						lolz = "Dono_Fundador";
					}
					if(away[i] == 0)
					{
					    if(admtrampando[i] == 1)
					    {
							format(string, 128, "{98F5FF}%s {FFFFFF}[%s] {98F5FF}(Trabalhando)\n", sendername, lolz);
							strcat(DialogThiago,string);
						}
						else
					    {
							format(string, 128, "{98F5FF}%s {FFFFFF}[%s] {9AFF9A}(Jogando)\n", sendername, lolz);
							strcat(DialogThiago,string);
						}

					}
					else
					{
						format(string, 128, "{98F5FF}%s {FFFFFF}[%s] {FF4040}(Ausente)\n", sendername, lolz);
						strcat(DialogKevin,string);
					}
					ShowPlayerDialog(playerid, 8789, DIALOG_STYLE_MSGBOX, "Administradores Online", DialogKevin, "Fechar", "");
				}
			}
		}
		return true;
	}
Reply
#6

pawn Код:
if(!strcmp(cmdtext,"/admins", true))
{
    static bool: result;
    for(new i; i < MAX_PLAYERS; ++i)
    {
        GetPlayerName(i,pname,24);
        if(IsPlayerConnected(i) && pAdmin[i] > 0)
        {
            if(pAdmin[i] == 1)
            {
                format(string,sizeof(string),"%s (%d) :: {3225EB}[Helper]", pname, i);
            }
            if(pAdmin[i] == 2)
            {
                format(string,sizeof(string),"%s (%d) :: {3225EB}[Adminstringador]", pname, i);
            }
            if(pAdmin[i] == 3)
            {
                format(string,sizeof(string),"%s (%d) :: {3225EB}[Administringador Chefe]", pname, i);
            }
            if(pAdmin[i] == 4)
            {
                format(string,sizeof(string),"%s (%d) ::{3225EB} [Sub Dono]", pname, i);
            }
            if(pAdmin[i] == 5)
            {
                format(string,sizeof(string),"%s (%d) :: {3225EB}[Dono]", pname, i);
            }
            ShowPlayerDialog(playerid, 0, DIALOG_STYLE_MSGBOX, "Adminstradores", string, "Fechar", "");
            result = true;
        }
    }
    if(!result)
        return SendClientMessage(playerid, Vermelho, "(ERRO) Nгo hб administradores online no momento");
}
Reply
#7

pawn Код:
if (!strcmp(cmdtext, "/admins", true)) {
    SendClientMessage(playerid, 0x00FF40AA, ".:: - Administradores Online - ::.");
    new strin[300];
    new count = 0;
    for (new i = 0; i < MAX_PLAYERS; i++) {
        if (IsPlayerConnected(i)) {
            if (admin[i]) {
                new str[256];
                new pname[24];
                GetPlayerName(i, pname, 24);
                format(file2, sizeof(file2), PASTA_CONTAS, pname);
                if (pAdmin[i] == 1) {
                    format(str, sizeof(str), "%s (%d) :: {3225EB}[Helper]\n", pname, i);
                }
                if (pAdmin[i] == 2) {
                    format(str, sizeof(str), "%s (%d) :: {3225EB}[Adminstrador]\n", pname, i);
                }
                if (pAdmin[i] == 3) {
                    format(str, sizeof(str), "%s (%d) :: {3225EB}[Administrador Chefe]\n", pname, i);
                }
                if (pAdmin[i] == 4) {
                    format(str, sizeof(str), "%s (%d) ::{3225EB} [Sub Dono]\n", pname, i);
                }
                if (pAdmin[i] == 5) {
                    format(str, sizeof(str), "%s (%d) :: {3225EB}[Dono]\n", pname, i);
                }
                strcat(strin, str);
                count++;
            }
        }
    }
    ShowPlayerDialog(playerid, 0, DIALOG_STYLE_MSGBOX, "Administradores Online", strin, "Fechar", "");
    if (count == 0) {
        SendClientMessage(playerid, Vermelho, "(ERRO) Nгo hб administradores online no momento");
    }
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)