[Help]GetPlayerMoney Error's
#1

This is the line of code i am using, and its trying to check if the players money is less than 'gunprice'

Код:
else if(GetPlayerMoney(playerid) < gunprice)
This is the bit so you know what gunprice is:

Код:
 	  new gunprice;
		gunprice = buyingweapongunprice[playerid];
and then i get this error on the line and its very annoying

Код:
C:\Documents and Settings\Darren\Desktop\GTA San Andreas\samp02Xserver.win32\gamemodes\FFrp.pwn(1113) : error 029: invalid expression, assumed zero
C:\Documents and Settings\Darren\Desktop\GTA San Andreas\samp02Xserver.win32\gamemodes\FFrp.pwn(1113) : warning 215: expression has no effect
C:\Documents and Settings\Darren\Desktop\GTA San Andreas\samp02Xserver.win32\gamemodes\FFrp.pwn(1113) : error 001: expected token: ";", but found "if"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


2 Errors.
Reply
#2

pawn Код:
else if(GetPlayerMoney(playerid) <= gunprice)
You forgot the = in <=
Reply
#3

i dont need a '=' I did less than, not less than and equal to...

Also when i add a '=' it gets same errors
Reply
#4

Ok then, what the fuck are you trying to do?
Reply
#5

trying to get rid of the Error..


The point of this statement is to check if the player's Money is less than ( < ) the 'gunprice'.. but im getting this error
Reply
#6

Why not #define the gunprice ?
Reply
#7

i dnno, i just want this thing FIXED
Reply
#8

What's the line before the else if check?
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)