Any way to disable player jumping if anything?
#3

You can do something like this,

pawn Код:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
    if(newkeys & KEY_JUMP)
    {
         if(Disabled[playerid])
         {
            new Float: pos[3];
            GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
            SetPlayerPos(playerid, pos[0], pos[1], pos[2]);
            ClearAnimations(playerid);
            return 1;
        }
   }
return 1;
}
Note it would clear the running animation, - how-ever you could apply a running animation in place using ApplyAnimation for a few seconds.
Reply


Messages In This Thread
Any way to disable player jumping if anything? - by [LvZ]Free - 16.10.2014, 22:00
Re: Any way to disable player jumping if anything? - by austin070 - 16.10.2014, 22:03
Re: Any way to disable player jumping if anything? - by Abagail - 16.10.2014, 22:26

Forum Jump:


Users browsing this thread: 1 Guest(s)