pawno errors
#1

I'm doing a jobs filterscript and in the line SweepingJob[playerid] = 1; (i've put at the top new SweepingJob[256]; ) pawno gave me these errors


Код:
C:\Users\Lollo\Music\eXtremeFR 2013x ES\filterscripts\JOBS.pwn(111) : error 017: undefined symbol "SweepingJob"
C:\Users\Lollo\Music\eXtremeFR 2013x ES\filterscripts\JOBS.pwn(111) : warning 215: expression has no effect
C:\Users\Lollo\Music\eXtremeFR 2013x ES\filterscripts\JOBS.pwn(111) : error 001: expected token: ";", but found "]"
C:\Users\Lollo\Music\eXtremeFR 2013x ES\filterscripts\JOBS.pwn(111) : error 029: invalid expression, assumed zero
C:\Users\Lollo\Music\eXtremeFR 2013x ES\filterscripts\JOBS.pwn(111) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


4 Errors.
Those are the codes


Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
    if (strcmp("/sweeper", cmdtext, true, 10) == 0)
    {
        if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 574)
        {
            SweepingJob[playerid] = 1;
            new name[MAX_PLAYER_NAME], string[48];
            GetPlayerName(playerid, name, sizeof(name));
            format(string, sizeof(string), "* %s is now a StreetSweeper.", name );
            SendClientMessageToAll(COLOR_YELLOW, string);
            SendClientMessage(playerid,COLOR_YELLOW,"* Clean the street for 1 minute and recieve $200");
            SetTimerEx("SweeperJobFinish", 60000, false, "i", playerid);
            return 1;
        }
        SendClientMessage(playerid, COLOR_RED,"You have to be in a streetsweeper to start the job");
    }
    return 0;
}
What i miss in this code? Thanx to everyone!
Reply
#2

pawn Код:
new SweepingJob[MAX_PLAYERS];
Reply
#3

Quote:
Originally Posted by kalanerik99
Посмотреть сообщение
pawn Код:
new SweepingJob[MAX_PLAYERS];
same errors

Код:
C:\Users\Lollo\Music\eXtremeFR 2013x ES\filterscripts\JOBS.pwn(111) : error 017: undefined symbol "SweepingJob"
C:\Users\Lollo\Music\eXtremeFR 2013x ES\filterscripts\JOBS.pwn(111) : warning 215: expression has no effect
C:\Users\Lollo\Music\eXtremeFR 2013x ES\filterscripts\JOBS.pwn(111) : error 001: expected token: ";", but found "]"
C:\Users\Lollo\Music\eXtremeFR 2013x ES\filterscripts\JOBS.pwn(111) : error 029: invalid expression, assumed zero
C:\Users\Lollo\Music\eXtremeFR 2013x ES\filterscripts\JOBS.pwn(111) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


4 Errors.
Reply
#4

BUMP!
Reply
#5

Put
PHP код:
new SweepingJob[MAX_PLAYERS]; 
Under the defines
Reply
#6

whichs line 111?
Reply
#7

Quote:
Originally Posted by kirollos
Посмотреть сообщение
whichs line 111?
this ---> SweepingJob[playerid] = 1;
Reply
#8

Quote:
Originally Posted by nor15
Посмотреть сообщение
Put
PHP код:
new SweepingJob[MAX_PLAYERS]; 
Under the defines
Already done but still appears these errors
Reply
#9

What's on the lines above it? I believe that's where your problem lies.
Reply
#10

Quote:
Originally Posted by Joe Staff
Посмотреть сообщение
What's on the lines above it? I believe that's where your problem lies.
Here the complete code
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)