Some errors
#5

of course this, but nvm
pawn Код:
if(strcmp(cmd, "/admincmds", true) == 0 || strcmp(cmd, "/acmd", true) == 0)
    {
        if(IsPlayerConnected(playerid))
        {
            if (PlayerInfo[playerid][pAdmin] < 1)
            {
                SendClientMessage(playerid, COLOR_RED, "You're not authorized to use this command!");
                return 1;
            }
            new plevel = PlayerInfo[playerid][pAdmin];
            new Adminhelp1[] = "/example /example /example /example /example /example ";
            new Adminhelp2[] = "/example /example /example /example /example /example ";
            new Adminhelp3[] = "/example /example /example /example /example /example /example /example ";
            new Adminhelp4[] = "/example /example /example /example /example /example ";
            new Adminhelp5[] = "/example /example /example /example ";
            new Adminhelp6[] = "/example /example /example /example /example /example ";
            new Adminhelp1337[] = "/example /example /example /example /example /example /example ";
            new Adminhelp1338[] = "/example /example /example /example /example /example /example /example ";
            new Adminhelpchat[] = "Type #<text> for the admin chat, or @<text> for the gamemaster chat.";
            tmp = strtok(cmdtext, idx);
            if(!strlen(tmp))
            {
                if(plevel == 1)
                {
                    format(string,sizeof(string), "%s\n%s",Adminhelp1[],Adminhelpchat[]);
                    ShowPlayerDialog(playerid, 3168, DIALOG_STYLE_MSGBOX,"AVAILABLE COMMANDS:", string,"Ok");
                }
                else if(plevel == 2)
                {
                    format(string,sizeof(string), "%s\n%s\n%s",Adminhelp1[],Adminhelp2[],Adminhelpchat[]);
                    ShowPlayerDialog(playerid, 3168, DIALOG_STYLE_MSGBOX,"AVAILABLE COMMANDS:", string,"Ok");
                }
                else if(plevel == 3)
                {
                    format(string,sizeof(string), "%s\n%s\n%s\n%s",Adminhelp1[],Adminhelp2[],Adminhelp3[],Adminhelpchat[]);
                    ShowPlayerDialog(playerid, 3168, DIALOG_STYLE_MSGBOX,"AVAILABLE COMMANDS:", string,"Ok");
                }
                else if(plevel == 4)
                {
                    format(string,sizeof(string), "%s\n%s\n%s\n%s\n%s",Adminhelp1[],Adminhelp2[],Adminhelp3[],Adminhelp4[],Adminhelpchat[]);
                    ShowPlayerDialog(playerid, 3168, DIALOG_STYLE_MSGBOX,"AVAILABLE COMMANDS:", string,"Ok");
                }
                else if(plevel == 5)
                {
                    format(string,sizeof(string), "%s\n%s\n%s\n%s\n%s\n%s",Adminhelp1[],Adminhelp2[],Adminhelp3[],Adminhelp4[],Adminhelp5[],Adminhelpchat[]);
                    ShowPlayerDialog(playerid, 3168, DIALOG_STYLE_MSGBOX,"AVAILABLE COMMANDS:", string,"Ok");
                }
                else if(plevel == 6)
                {
                    format(string,sizeof(string), "%s\n%s\n%s\n%s\n%s\n%s\n%s",Adminhelp1[],Adminhelp2[],Adminhelp3[],Adminhelp4[],Adminhelp5[],Adminhelp6[],Adminhelpchat[]);
                    ShowPlayerDialog(playerid, 3168, DIALOG_STYLE_MSGBOX,"AVAILABLE COMMANDS:", string,"Ok");
                }
                else if(plevel == 1337)
                {
                    format(string,sizeof(string), "%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s",Adminhelp1[],Adminhelp2[],Adminhelp3[],Adminhelp4[],Adminhelp5[],Adminhelp6[],Adminhelp1337[],Adminhelpchat[]);
                    ShowPlayerDialog(playerid, 3168, DIALOG_STYLE_MSGBOX,"AVAILABLE COMMANDS:", string,"Ok");
                }
                else if(plevel == 1338)
                {
                    format(string,sizeof(string), "%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s",Adminhelp1[],Adminhelp2[],Adminhelp3[],Adminhelp4[],Adminhelp5[],Adminhelp6[],Adminhelp1337[],Adminhelp1338[],Adminhelpchat[]);
                    ShowPlayerDialog(playerid, 3168, DIALOG_STYLE_MSGBOX,"AVAILABLE COMMANDS:", string,"Ok");
                }
                return 1;
            }
            }
    }
but this
pawn Код:
new Adminhelp1[] = "/example /example /example /example /example /example ";
and this
pawn Код:
if(plevel == 1)
                {
                    format(string,sizeof(string), "%s\n%s",Adminhelp1[],Adminhelpchat[]);
                    ShowPlayerDialog(playerid, 3168, DIALOG_STYLE_MSGBOX,"AVAILABLE COMMANDS:", string,"Ok");
                }
are the errors
Reply


Messages In This Thread
Some errors - by Black_Sun1 - 10.09.2011, 22:14
Re: Some errors - by Retardedwolf - 10.09.2011, 22:31
Re: Some errors - by Black_Sun1 - 10.09.2011, 22:35
Re: Some errors - by Yamoo - 10.09.2011, 22:43
Re: Some errors - by Black_Sun1 - 10.09.2011, 22:46
Re: Some errors - by =WoR=G4M3Ov3r - 11.09.2011, 00:30
Re: Some errors - by Sasino97 - 11.09.2011, 00:55
Re: Some errors - by Black_Sun1 - 11.09.2011, 15:40

Forum Jump:


Users browsing this thread: 1 Guest(s)