30.03.2013, 15:10
pawn Код:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
if(newkeys & KEY_JUMP)
{
new Float:x, Float:y, Float:z;
GetPlayerVelocity(playerid, x, y, z);
if(y > changethistoheightvalue)
{
new Float:health;
GetPlayerHealth(playerid, health);
SetPlayerHealth(playerid, health-80);
}
}
return 1;
}