a lot of error messages
#1

Heres the parts thats causing errors:
pawn Код:
public OnPlayerDeath(playerid, killerid, reason)
{
    PlayerInfo[killerid][pKills]++;
    PlayerInfo[playerid][pDeaths]++;
    PlayerInfo[playerid][pScore] + 2;
   
    ServerInfo[sKills]++;
    ServerInfo[sDeaths]++;
    return 1;
}

And heres the errors:
Код:
C:\Users\Keegan\Desktop\filterscripts\WWAdmin.pwn(193) : warning 215: expression has no effect
C:\Users\Keegan\Desktop\filterscripts\WWAdmin.pwn(195) : error 028: invalid subscript (not an array or too many subscripts): "ServerInfo"
C:\Users\Keegan\Desktop\filterscripts\WWAdmin.pwn(195) : warning 215: expression has no effect
C:\Users\Keegan\Desktop\filterscripts\WWAdmin.pwn(195) : error 001: expected token: ";", but found "]"
C:\Users\Keegan\Desktop\filterscripts\WWAdmin.pwn(195) : error 029: invalid expression, assumed zero
C:\Users\Keegan\Desktop\filterscripts\WWAdmin.pwn(195) : fatal error 107: too many error messages on one line

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


4 Errors.
Please help.
Reply
#2

How you created ServerInfo?
And these
Код:
PlayerInfo[playerid][pScore] + 2;
should be
Код:
PlayerInfo[playerid][pScore] += 2;
Reply
#3

yes, i can show you the array:
pawn Код:
enum ServerInfo
{
    sPlayers,
    sBans,
    sKicks,
    sWarns,
    sMutes,
    sKills,
    sDeaths
}
Reply
#4

pawn Код:
ServerInfo[SKills]++;
ServerInfo[SDeaths]++;
And Make sure you have this
pawn Код:
enum ServerInfo
{
      SKills,
      SDeaths
}

and have you?
#define ServerInfo /path?
Reply
#5

Try
Код:
enum SInfo
{
    sPlayers,
    sBans,
    sKicks,
    sWarns,
    sMutes,
    sKills,
    sDeaths
}
new ServerInfo[MAX_PLAYERS][SInfo];
Код:
ServerInfo[playerid][sKills]++;
    ServerInfo[playerid][sDeaths]++;
Reply
#6

Thanks guys rep+ to both
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)