Error help
#1

Error help heres the code:
pawn Код:
switch(listitem) {
                case 0: {
                    if(playerVariables[playerid][pMaterials] >= 30) {
                        if(playerVariables[playerid][pScrewDriver] == 1) {
                        givePlayerValidWeapon(playerid, 8);
                        playerVariables[playerid][pMaterials] -= 30;
                        SendClientMessage(playerid, COLOR_WHITE, "You have created a katana. Type /giveweapon [playerid] to pass the weapon on.");
                        format(szMessage, sizeof(szMessage), "* %s has created a katana from their materials.", szPlayerName);
                        nearByMessage(playerid, COLOR_PURPLE, szMessage);
                        playerVariables[playerid][pJobDelay] = 30;
                        playerVariables[playerid][pJobSkill][0]++;
                        switch(playerVariables[playerid][pJobSkill][0]) {
                            case 50, 100, 150, 200, 250, 300, 350, 400, 450, 500: {
                                format(szMessage,sizeof(szMessage),"Congratulations! Your weapon creation skill level is now %d. You can now create more powerful weapons.",playerVariables[playerid][pJobSkill][0]/50);
                                SendClientMessage(playerid,COLOR_WHITE,szMessage);
                            }
                        }
The errors:
pawn Код:
Arko.pwn(8231) : error 014: invalid statement; not in switch
Arko.pwn(8231) : warning 215: expression has no effect
Arko.pwn(8231) : error 001: expected token: ";", but found ":"
Arko.pwn(8231) : error 029: invalid expression, assumed zero
Arko.pwn(8231) : fatal error 107: too many error messages on one line
Heres the line that i add that makes the errors appear if(playerVariables[playerid][pScrewDriver] == 1) {

Can someone please help me.
Reply


Messages In This Thread
Error help - by arko123 - 09.12.2012, 15:13
Re: Error help - by tsonn1 - 09.12.2012, 15:17
Re: Error help - by arko123 - 09.12.2012, 15:20
Re: Error help - by tsonn1 - 09.12.2012, 15:21
Re: Error help - by arko123 - 09.12.2012, 15:23

Forum Jump:


Users browsing this thread: 1 Guest(s)