[HELP]KeyStateCHange not working
#1

Ok when some bunny hops it is supposed to slap them and say don't bunny hop when pressing shift but it doesnt work and c-bug either doesnt work
Код:
	else if (newkeys==KEY_FIRE && newkeys==KEY_CROUCH)
  {
  TogglePlayerControllable(playerid, 0);
  	SendClientMessage(playerid,COLOR_YELLOW,"DONT C-BUG you have been frozend tell a admin to unfreeze you");
  }

  	else if(newkeys == KEY_JUMP)
  {
  
	if(GetPlayerState(playerid) == PLAYER_STATE_ONFOOT)
  {
  	new Float:shealth;
	new Float:slx, Float:sly, Float:slz;
	GetPlayerHealth(playerid, shealth);
	SetPlayerHealth(playerid, shealth-5);
	GetPlayerPos(playerid, slx, sly, slz);
	SetPlayerPos(playerid, slx, sly, slz+5);
	PlayerPlaySound(playerid, 1130, slx, sly, slz+5);
	{
  	SendClientMessage(playerid,COLOR_YELLOW,"DONT Bunny HOP");
	return 1;
	}
	}
	}
Reply
#2

https://sampwiki.blast.hk/wiki/OnPlayerK...heck_for_a_key
Reply
#3

Never mine i fixed but how can i make it show when they are running and jumping it slaps dem and says don't bunny hop
Reply
#4

Did you even bother looking at the link ?
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)