Lock by Dissconect
#4

A good start, but the problem is that you compare with a single = in the if. In pawn, a single = is used only to assign values to an variable. To compare them, use double =
Another minor mistake is that 'state' is a pawn keyword and you cant use it as variable name, just change it like this and it will work.

pawn Код:
new playerstate = GetPlayerState(playerid);   // Assigning the value to the variable, so a single = is correct
if(playerstate == PLAYER_STATE_DRIVER)     //to check if two values are equal use two =
Reply


Messages In This Thread
Lock by Dissconect - by SanAndreasVille - 26.01.2011, 14:22
Re: Lock by Dissconect - by Mauzen - 26.01.2011, 17:07
Re: Lock by Dissconect - by SanAndreasVille - 26.01.2011, 17:58
Re: Lock by Dissconect - by Mauzen - 26.01.2011, 20:33
Re: Lock by Dissconect - by SanAndreasVille - 26.01.2011, 22:00

Forum Jump:


Users browsing this thread: 1 Guest(s)