SA-MP Forums Archive
problem with /buylevel - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: problem with /buylevel (/showthread.php?tid=111768)



problem with /buylevel - The_Pain - 03.12.2009

I have some error from my command i dont know how to fix that, can you tell how i can fix that?

Command
Quote:

if (strcmp("/buylevel", cmdtext, true, 10) == 0)
{
SetPlayerRank(playerid, 1);
GivePlayerMoney(playerid, -350000);
SendClientMessage(playerid, 0x33AA33AA,"Apsveicam! Tu esi iegadajies 1 levelu!");
} else {
SendClientMessage(playerid, 0x33AA33AA,"Piedod! Bet tev nepietiek naudas lai nopirktu 1 levelu!");
}
return 1;

Quote:

Error
C:\Users\Administrator\Desktop\Deyfon\gamemodes\le vels.pwn(57) : error 017: undefined symbol "SetPlayerRank"
C:\Users\Administrator\Desktop\Deyfon\gamemodes\le vels.pwn(64) : warning 225: unreachable code
C:\Users\Administrator\Desktop\Deyfon\gamemodes\le vels.pwn(66) : warning 203: symbol is never used: "strtok"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


1 Error.




Re: problem with /buylevel - Pwnzor - 03.12.2009

If im right you have to define "SetPlayerRank" at the top of the script....but i've lost all my samp files and havent scripted in a while

hope it helped


Re: problem with /buylevel - The_Pain - 03.12.2009

Errors fixed but now i have warnings

Quote:

C:\Users\Administrator\Desktop\Deyfon\gamemodes\le vels.pwn(59) : warning 215: expression has no effect
C:\Users\Administrator\Desktop\Deyfon\gamemodes\le vels.pwn(66) : warning 225: unreachable code
C:\Users\Administrator\Desktop\Deyfon\gamemodes\le vels.pwn(6 : warning 203: symbol is never used: "strtok"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


3 Warnings.