27.10.2018, 12:45 
	
	
	
		Hello.
When I enter the following code in these params:
I want see this dialog:

but I see this dialog:

My code:
	
	
	
	
When I enter the following code in these params:
Код:
/amsg 0 No problem.\nIt's a bug.\nYou can report it on www.example.com/report-bugs // CMD: /amsg [playerid] [text]

but I see this dialog:

My code:
PHP код:
dcmd_amsg(playerid,params[])
{
    if(AccInfo[playerid][Level] >= 1 && AccInfo[playerid][LoggedIn] == 1)
    {
        new text[256], id;
        new str[128];
        if(sscanf(params, "us[256]",id,text)) return GameTextForPlayer(playerid,"~g~/amsg ~w~(id) (text)",3000,3);
        
          if(AccInfo[id][Level] == ServerInfo[MaxAdminLevel] && AccInfo[playerid][Level] != ServerInfo[MaxAdminLevel]) return GameTextForPlayer(playerid,"~r~~h~ERROR: You cannot use this command on this admin",6000,3);
        if(!IsPlayerConnected(id)) return GameTextForPlayer(playerid,"~r~player is not connected",4000,3);
        
        format(str,sizeof(str),"{FFFFFF}%s",text);
        ShowPlayerDialog(id,13003,DIALOG_STYLE_MSGBOX,"{00FF00}Admins Message",str,"Close","");
    }
    return 1;
} 

