one error
#1

pawn Код:
if(IsPlayerInRangeOfPoint(i, 20.0, X, Y, Z) && gTeam[i] == TEAM_CIVIL[i] && GetPlayerWantedLevel(i) < 4 && IsFrozen[i] != 1 && InAdminMode[i] != 1 && HasTicket[i] != 1)
Код:
E:\San Andreas Cops and Criminals\San Andreas Cops and Criminals\Version 0.5\gamemodes\SACNCv0.5.pwn(5678) : error 001: expected token: ";", but found "]"
Reply
#2

pawn Код:
if( (IsPlayerInRangeOfPoint(i, 20.0, X, Y, Z)) && (gTeam[i] == TEAM_CIVIL[i]) && (GetPlayerWantedLevel(i) < 4) && (IsFrozen[i] != 1) && (IsAdminMode[i] != 1) && (HasTicket[i] != 1))
You closed the if statement right after IsPlayerInRangeOfPoint, I've fixed it for you.
Small issues that are easy to fix, my TIP: Re-write the line, you'll probably notice it.
EDIT: Oh well, my keyboard just spazzed out and made me see the wrong error. Let me look at it again, I've just declared anothe error.
EDIT #2: I believe this should work, I've found out nothing wrong with the line after re-writing it three times. Are you sure this is the line?

It might be due to a variable being declared wrongfully or something mixing up inside the script.
Reply
#3

made it
pawn Код:
if(IsPlayerInRangeOfPoint(i, 20.0, X, Y, Z))
                   {
                     if(gTeam[i] == TEAM_CIVIL[i] && GetPlayerWantedLevel(i) < 4 && IsFrozen[i] != 1 && InAdminMode[i] != 1 && HasTicket[i] != 1)
                     {
same error still in the second line.
Reply
#4

pawn Код:
if(IsPlayerInRangeOfPoint(i, 20.0, X, Y, Z))
        if(gTeam[i] == TEAM_CIVIL[i])
            if(GetPlayerWantedLevel(i) < 4)
                if(IsFrozen[i] != 1)
                    if(IsAdminMode[i] != 1)
                        if(HasTicket[i] != 1)
Add that and tell me which line of those has the error, as I suspect you're declaring something wrongfully and it translates into that error inside the if.
Reply
#5

if(gTeam[i] == TEAM_CIVIL[i])
and
if(IsAdminMode[i] != 1)
Reply
#6

pawn Код:
gTeam[i] == TEAM_CIVIL[i]
It should be:
pawn Код:
gTeam[i] == TEAM_CIVIL
Reply
#7

we're fucking idiots, fixed.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)