13.01.2011, 20:42
Hey. Okay so I am trying to make a /stats command. I found a good function in SAGC script and decided to use it in my script. Here is the error I get;
Here is my code;
At top of the script (above main()):
/stats commands:
The function at the bottom of the script:
Here is the code I remade into the above code, see if I forgot to add something to my code;
http://pastebin.com/cDBmeKPi
If there is anything else I must post in order to solve this, just tell and I will do it.
Thanks for reading! Please reply if you have a solution for this.
pawn Код:
myscript.pwn(267) : error 004: function "ShowStats" is not implemented
At top of the script (above main()):
pawn Код:
forward ShowStats(playerid,targetid);
pawn Код:
if(strcmp(cmd, "/stats", true) == 0)
{
ShowStats(playerid,playerid); [COLOR="Red"]This is the error line, 267.[/COLOR]
return 1;
}
pawn Код:
public ShowStats(playerid,targetid)
{
if(IsPlayerConnected(playerid)&&IsPlayerConnected(targetid))
{
if(gPlayerLogged[targetid])
{
SendClientMessage(playerid,COLOR_FUNNYGREEN,"STATS");
new wstring[128];
new score = PlayerInfo[targetid][pScore];
GetPlayerHealth(targetid,hp);
format(wstring, sizeof(wstring), "Level: %d | Hдlsa: %.1f",score, hp);
SendClientMessage(playerid,COLOR_WHITE, wstring);
}
}
}
http://pastebin.com/cDBmeKPi
If there is anything else I must post in order to solve this, just tell and I will do it.
Thanks for reading! Please reply if you have a solution for this.
