I think the problem is defining - OnPlayerKeyStateChange
#1

Ok, so i didn't understand the define things in the tutorial on sa-mp wiki...so..here is what i got


public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
#define PRESSED(%0) \
if (PRESSED(KEY_JUMP))
{
new
Float:X5,
Float:Y5,
Float:Z5;
GetPlayerPos(playerid, X5, Y5, Z5);
SetPlayerPos(playerid, X5, Y5, Z5 + 10.0);
}
return 1;
}


and i get this warning: warning 201: redefinition of constant/macro (symbol "PRESSED(%0)")

on the if (pressed line
Reply


Messages In This Thread
I think the problem is defining - OnPlayerKeyStateChange - by gnoomen2 - 14.08.2012, 00:50
Re: I think the problem is defining - OnPlayerKeyStateChange - by gnoomen2 - 14.08.2012, 01:01
Re: I think the problem is defining - OnPlayerKeyStateChange - by gnoomen2 - 14.08.2012, 01:14

Forum Jump:


Users browsing this thread: 1 Guest(s)