#1

i got errors plz help me
Код:
(7875) : error 028: invalid subscript (not an array or too many subscripts): "PlayerInfo"
(7875) : warning 215: expression has no effect
(7875) : error 001: expected token: ";", but found "]"
(7875) : error 029: invalid expression, assumed zero
(7875) : fatal error 107: too many error messages on one line

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

Код:
CMD:stats(playerid, params[])
{
    new RobSkill = PlayerInfo[playerid][RobSkill];
    new ArmyPermission = PlayerInfo[playerid][ArmyPermission];
    new Score = PlayerInfo[playerid][Score];
    new string[256], sendername[MAX_PLAYER_NAME];
    format(string,sizeof(string), "PlayerName:( %s ) Admin Level:[ %d ] Kills:[ %d ] Deaths:[ %d ] ArmyPermissions:%d",sendername,Score,ArmyPermissions,RobSkill);
    ShowPlayerDialog(playerid, 0, DIALOG_STYLE_MSGBOX , "Stats", string, "Close", "");
    return 1;
}
Reply
#2

Why dont use it like this?

pawn Код:
CMD:stats(playerid, params[])
{
    new string[256], sendername[MAX_PLAYER_NAME];
    GetPlayerName(sendername, sizeof(sendername));
    format(string,sizeof(string), "PlayerName:( %s ) Admin Level:[ %d ] Kills:[ %d ] Deaths:[ %d ] ArmyPermissions:%d",sendername,GetPlayerScore(playerid),PlayerInfo[playerid][ArmyPermission],PlayerInfo[playerid][RobSkill]);
    ShowPlayerDialog(playerid, 0, DIALOG_STYLE_MSGBOX , "Stats", string, "Close", "");
    return 1;
}
+ I think you messed up the format due to in AdminLevel will print the score, in Kills will print Army permissions and in Deaths will print the RobSkill.
Reply
#3

Код:
(7876) : error 035: argument type mismatch (argument 1)
(7876) : error 035: argument type mismatch (argument 2)
(7877) : error 028: invalid subscript (not an array or too many subscripts): "PlayerInfo"
(7877) : warning 215: expression has no effect
(7877) : error 001: expected token: ";", but found "]"
(7877) : error 029: invalid expression, assumed zero
(7877) : fatal error 107: too many error messages on one line

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


6 Errors.
Reply
#4

Show us all the script.
Reply
#5

Here:
http://forum.sa-mp.com/showthread.ph...s+Cops+Robbers
Reply
#6

Any help?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)