Dialog size
#1

Hi I'm creating a command to view all possible admin commands however I get an error stating that the string is too long. I was wondering how would I make the dialog bigger or something else?

PHP код:
    if(dialogid == DIALOG_CMDS_ADMIN)
    {
        if(
response)
        {
            if(
PlayerInfo[playerid][pAdmin] == 1)
            {
                switch(
listitem)
                {
                    case 
0:    ShowPlayerDialog(playeridDIALOG_RP_CMDSDIALOG_STYLE_MSGBOX"Roleplay Commands""/me, /do, /s, /shout""Close","");
                    case 
1:    ShowPlayerDialog(playeridDIALOG_VEH_CMDSDIALOG_STYLE_MSGBOX"Vehicle Commands""/opendoors, /closedoors, /opencarwindows, /closecarwindows, /openboot, /closeboot, /openbonnet, /closebonnet, /engine, /lights, /kph, /mph, /hidspeedo, /showspeedo""Close","");
                    case 
2:    ShowPlayerDialog(playeridDIALOG_GEN_CMDSDIALOG_STYLE_MSGBOX"General Commands""/admins, /afk, /back, /help, /report, /ask, /commands, /actions, /changename, /password, /civil""Close","");
                    case 
3:    ShowPlayerDialog(playeridDIALOG_PH_CMDSDIALOG_STYLE_MSGBOX"House Commands""/buyprop, /sellprop, /lockprop, /propdoor""Close","");
                    case 
4:    ShowPlayerDialog(playeridDIALOG_PORG_CMDSDIALOG_STYLE_MSGBOX"Organization Commands""/org, /ochat, /lc, /orgs, /want""Close","");
                    case 
5:    ShowPlayerDialog(playeridDIALOG_PBUS_CMDSDIALOG_STYLE_MSGBOX"Business Commands""/bnear, /buybus, /sellbus, /lockbus, /busdoor""Close","");
                    case 
6:    ShowPlayerDialog(playeridDIALOG_SCMDSDIALOG_STYLE_MSGBOX"{00E5EE}Support Commands""/sc, /scolor, /reply, /declinehelp""Close","");
                    case 
7:    ShowPlayerDialog(playeridDIALOG_ACMDSDIALOG_STYLE_MSGBOX"{FF0000}Admininstrator Commands""{DB881A}Level 1{FFFFFF} - /asay, /kick, /freeze, /unfreeze, /ac, /clear, /disarm, /checkplayer, /spectate, /stopspec, /acceptreport, /declinereport, /reports, /weather""Close","");
                    case 
8ShowPlayerDialog(playeridDIALOG_VIP_CMDSDIALOG_STYLE_MSGBOX"{FF69B4}VIP Commands""Nothing here, yet""Close","");
                }
            }
            else if(
PlayerInfo[playerid][pAdmin] == 2)
            {
                switch(
listitem)
                {
                    case 
0:    ShowPlayerDialog(playeridDIALOG_RP_CMDSDIALOG_STYLE_MSGBOX"Roleplay Commands""/me, /do, /s, /shout""Close","");
                    case 
1:    ShowPlayerDialog(playeridDIALOG_VEH_CMDSDIALOG_STYLE_MSGBOX"Vehicle Commands""/opendoors, /closedoors, /opencarwindows, /closecarwindows, /openboot, /closeboot, /openbonnet, /closebonnet, /engine, /lights, /kph, /mph, /hidspeedo, /showspeedo""Close","");
                    case 
2:    ShowPlayerDialog(playeridDIALOG_GEN_CMDSDIALOG_STYLE_MSGBOX"General Commands""/admins, /afk, /back, /help, /report, /ask, /commands, /actions, /changename, /password, /civil""Close","");
                    case 
3:    ShowPlayerDialog(playeridDIALOG_PH_CMDSDIALOG_STYLE_MSGBOX"House Commands""/buyprop, /sellprop, /lockprop, /propdoor""Close","");
                    case 
4:    ShowPlayerDialog(playeridDIALOG_PORG_CMDSDIALOG_STYLE_MSGBOX"Organization Commands""/org, /ochat, /lc, /orgs, /want""Close","");
                    case 
5:    ShowPlayerDialog(playeridDIALOG_PBUS_CMDSDIALOG_STYLE_MSGBOX"Business Commands""/bnear, /buybus, /sellbus, /lockbus, /busdoor""Close","");
                    case 
6:    ShowPlayerDialog(playeridDIALOG_SCMDSDIALOG_STYLE_MSGBOX"{00E5EE}Support Commands""/sc, /scolor, /reply, /declinehelp""Close","");
                    case 
7:    ShowPlayerDialog(playeridDIALOG_ACMDSDIALOG_STYLE_MSGBOX"{FF0000}Admininstrator Commands""{DB881A}Level 1{FFFFFF} - /asay, /kick, /freeze, /unfreeze, /ac, /clear, /disarm, /checkplayer, /spectate, /stopspec, /acceptreport, /declinereport, /reports, /weather\n{1B1BE0}Level 2{FFFFFF} - /goto, /get, /banip, /ban, /listen, /settime""Close","");
                    case 
8ShowPlayerDialog(playeridDIALOG_VIP_CMDSDIALOG_STYLE_MSGBOX"{FF69B4}VIP Commands""Nothing here, yet""Close","");
                }
            }
            else if(
PlayerInfo[playerid][pAdmin] == 3)
            {
                switch(
listitem)
                {
                    case 
0:    ShowPlayerDialog(playeridDIALOG_RP_CMDSDIALOG_STYLE_MSGBOX"Roleplay Commands""/me, /do, /s, /shout""Close","");
                    case 
1:    ShowPlayerDialog(playeridDIALOG_VEH_CMDSDIALOG_STYLE_MSGBOX"Vehicle Commands""/opendoors, /closedoors, /opencarwindows, /closecarwindows, /openboot, /closeboot, /openbonnet, /closebonnet, /engine, /lights, /kph, /mph, /hidspeedo, /showspeedo""Close","");
                    case 
2:    ShowPlayerDialog(playeridDIALOG_GEN_CMDSDIALOG_STYLE_MSGBOX"General Commands""/admins, /afk, /back, /help, /report, /ask, /commands, /actions, /changename, /password, /civil""Close","");
                    case 
3:    ShowPlayerDialog(playeridDIALOG_PH_CMDSDIALOG_STYLE_MSGBOX"House Commands""/buyprop, /sellprop, /lockprop, /propdoor""Close","");
                    case 
4:    ShowPlayerDialog(playeridDIALOG_PORG_CMDSDIALOG_STYLE_MSGBOX"Organization Commands""/org, /ochat, /lc, /orgs, /want""Close","");
                    case 
5:    ShowPlayerDialog(playeridDIALOG_PBUS_CMDSDIALOG_STYLE_MSGBOX"Business Commands""/bnear, /buybus, /sellbus, /lockbus, /busdoor""Close","");
                    case 
6:    ShowPlayerDialog(playeridDIALOG_SCMDSDIALOG_STYLE_MSGBOX"{00E5EE}Support Commands""/sc, /scolor, /reply, /declinehelp""Close","");
                    case 
7:    ShowPlayerDialog(playeridDIALOG_ACMDSDIALOG_STYLE_MSGBOX"{FF0000}Admininstrator Commands""{DB881A}Level 1{FFFFFF} - /asay, /kick, /freeze, /unfreeze, /ac, /clear, /disarm, /checkplayer, /spectate, /stopspec, /acceptreport, /declinereport, /reports, /weather\n{1B1BE0}Level 2{FFFFFF} - /goto, /get, /banip, /ban, /listen, /settime\n{7340DB}Level 3{FFFFFF} - /vdestroy, /heal, /giveweapon, /setskin, /givemoney, /deleteport, /deleteallreports, /setfuel""Close","");
                    case 
8ShowPlayerDialog(playeridDIALOG_VIP_CMDSDIALOG_STYLE_MSGBOX"{FF69B4}VIP Commands""Nothing here, yet""Close","");
                }
            }
            else if(
PlayerInfo[playerid][pAdmin] == 4)
            {
                switch(
listitem)
                {
                    case 
0:    ShowPlayerDialog(playeridDIALOG_RP_CMDSDIALOG_STYLE_MSGBOX"Roleplay Commands""/me, /do, /s, /shout""Close","");
                    case 
1:    ShowPlayerDialog(playeridDIALOG_VEH_CMDSDIALOG_STYLE_MSGBOX"Vehicle Commands""/opendoors, /closedoors, /opencarwindows, /closecarwindows, /openboot, /closeboot, /openbonnet, /closebonnet, /engine, /lights, /kph, /mph, /hidspeedo, /showspeedo""Close","");
                    case 
2:    ShowPlayerDialog(playeridDIALOG_GEN_CMDSDIALOG_STYLE_MSGBOX"General Commands""/admins, /afk, /back, /help, /report, /ask, /commands, /actions, /changename, /password, /civil""Close","");
                    case 
3:    ShowPlayerDialog(playeridDIALOG_PH_CMDSDIALOG_STYLE_MSGBOX"House Commands""/buyprop, /sellprop, /lockprop, /propdoor""Close","");
                    case 
4:    ShowPlayerDialog(playeridDIALOG_PORG_CMDSDIALOG_STYLE_MSGBOX"Organization Commands""/org, /ochat, /lc, /orgs, /want""Close","");
                    case 
5:    ShowPlayerDialog(playeridDIALOG_PBUS_CMDSDIALOG_STYLE_MSGBOX"Business Commands""/bnear, /buybus, /sellbus, /lockbus, /busdoor""Close","");
                    case 
6:    ShowPlayerDialog(playeridDIALOG_SCMDSDIALOG_STYLE_MSGBOX"{00E5EE}Support Commands""/sc, /scolor, /reply, /declinehelp""Close","");
                    case 
7:    ShowPlayerDialog(playeridDIALOG_ACMDSDIALOG_STYLE_MSGBOX"{FF0000}Admininstrator Commands""{DB881A}Level 1{FFFFFF} - /asay, /kick, /freeze, /unfreeze, /ac, /clear, /disarm, /checkplayer, /spectate, /stopspec, /acceptreport, /declinereport, /reports, /weather\n{1B1BE0}Level 2{FFFFFF} - /goto, /get, /banip, /ban, /listen, /settime\n{7340DB}Level 3{FFFFFF} - /vdestroy, /heal, /giveweapon, /setskin, /givemoney, /deleteport, /deleteallreports, /setfuel\n{8CED15}Level 4{FFFFFF} - /oban, /unban, /sac, /vehicle, /healall, /dycmds, /setsmember, /setname""Close","");
                    case 
8ShowPlayerDialog(playeridDIALOG_VIP_CMDSDIALOG_STYLE_MSGBOX"{FF69B4}VIP Commands""Nothing here, yet""Close","");
                }
            }
            else
            {
                switch(
listitem)
                {
                    case 
0:    ShowPlayerDialog(playeridDIALOG_RP_CMDSDIALOG_STYLE_MSGBOX"Roleplay Commands""/me, /do, /s, /shout""Close","");
                    case 
1:    ShowPlayerDialog(playeridDIALOG_VEH_CMDSDIALOG_STYLE_MSGBOX"Vehicle Commands""/opendoors, /closedoors, /opencarwindows, /closecarwindows, /openboot, /closeboot, /openbonnet, /closebonnet, /engine, /lights, /kph, /mph, /hidspeedo, /showspeedo""Close","");
                    case 
2:    ShowPlayerDialog(playeridDIALOG_GEN_CMDSDIALOG_STYLE_MSGBOX"General Commands""/admins, /afk, /back, /help, /report, /ask, /commands, /actions, /changename, /password, /civil""Close","");
                    case 
3:    ShowPlayerDialog(playeridDIALOG_PH_CMDSDIALOG_STYLE_MSGBOX"House Commands""/buyprop, /sellprop, /lockprop, /propdoor""Close","");
                    case 
4:    ShowPlayerDialog(playeridDIALOG_PORG_CMDSDIALOG_STYLE_MSGBOX"Organization Commands""/org, /ochat, /lc, /orgs, /want""Close","");
                    case 
5:    ShowPlayerDialog(playeridDIALOG_PBUS_CMDSDIALOG_STYLE_MSGBOX"Business Commands""/bnear, /buybus, /sellbus, /lockbus, /busdoor""Close","");
                    case 
6:    ShowPlayerDialog(playeridDIALOG_SCMDSDIALOG_STYLE_MSGBOX"{00E5EE}Support Commands""/sc, /scolor, /reply, /declinehelp""Close","");
                    case 
7ShowPlayerDialog(playeridDIALOG_CMDS_ADMINDIALOG_STYLE_MSGBOX"{FF0000}Admininistrator Commands""{DB881A}Level 1{FFFFFF} - /asay, /kick, /freeze, /unfreeze, /ac, /clear, /disarm, /checkplayer, /spectate, /stopspec, /acceptreport, /declinereport, /reports, /weather
                    \n{1B1BE0}Level 2{FFFFFF} - /goto, /get, /banip, /ban, /listen, /settime\n{7340DB}Level 3{FFFFFF} - /vdestroy, /heal, /giveweapon, /setskin, /givemoney, /deleteport, /deleteallreports, /setfuel\n{8CED15}Level 4{FFFFFF} - /oban, /unban, /sac, /vehicle, /healall, /dycmds, /setsmember, /setname\n{37DB45}Level 5{FFFFFF} - /setadmin, /setadminuc, /gmx, /asetpass"
"Back""Close");
                    case 
8ShowPlayerDialog(playeridDIALOG_VIP_CMDSDIALOG_STYLE_MSGBOX"{FF69B4}VIP Commands""Nothing here, yet""Close","");
                }
            }
        }
    }
    return 
1;

The error starts happening here at level 4 when the string gets long.
Код:
                    case 7:    ShowPlayerDialog(playerid, DIALOG_ACMDS, DIALOG_STYLE_MSGBOX, "{FF0000}Admininstrator Commands", "{DB881A}Level 1{FFFFFF} - /asay, /kick, /freeze, /unfreeze, /ac, /clear, /disarm, /checkplayer, /spectate, /stopspec, /acceptreport, /declinereport, /reports, /weather\n{1B1BE0}Level 2{FFFFFF} - /goto, /get, /banip, /ban, /listen, /settime\n{7340DB}Level 3{FFFFFF} - /vdestroy, /heal, /giveweapon, /setskin, /givemoney, /deleteport, /deleteallreports, /setfuel\n{8CED15}Level 4{FFFFFF} - /oban, /unban, /sac, /vehicle, /healall, /dycmds, /setsmember, /setname", "Close","");
And also continues onto level 5.

Код:
case 7: ShowPlayerDialog(playerid, DIALOG_CMDS_ADMIN, DIALOG_STYLE_MSGBOX, "{FF0000}Admininistrator Commands", "{DB881A}Level 1{FFFFFF} - /asay, /kick, /freeze, /unfreeze, /ac, /clear, /disarm, /checkplayer, /spectate, /stopspec, /acceptreport, /declinereport, /reports, /weather
					\n{1B1BE0}Level 2{FFFFFF} - /goto, /get, /banip, /ban, /listen, /settime\n{7340DB}Level 3{FFFFFF} - /vdestroy, /heal, /giveweapon, /setskin, /givemoney, /deleteport, /deleteallreports, /setfuel\n{8CED15}Level 4{FFFFFF} - /oban, /unban, /sac, /vehicle, /healall, /dycmds, /setsmember, /setname\n{37DB45}Level 5{FFFFFF} - /setadmin, /setadminuc, /gmx, /asetpass", "Back", "Close");
Reply


Messages In This Thread
Dialog size - by Tass007 - 19.08.2016, 08:49
Re: Dialog size - by Konstantinos - 19.08.2016, 09:00
Re: Dialog size - by Tass007 - 19.08.2016, 09:11
Re: Dialog size - by DeeadPool - 19.08.2016, 09:40
Re: Dialog size - by Tass007 - 19.08.2016, 10:04
Re: Dialog size - by Konstantinos - 19.08.2016, 10:20
Re: Dialog size - by Tass007 - 19.08.2016, 10:43
Re: Dialog size - by Konstantinos - 19.08.2016, 10:56

Forum Jump:


Users browsing this thread: 1 Guest(s)