Help me, please. Thanks.
#1

Код:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
  if (IsKeyJustDown(KEY_FIRE, newkeys, oldkeys))
  {
    if(IsPlayerConnected(playerid))
	{
	  if(GetPlayerWeapon(playerid) == 40)
	  {
        if (PlayerInfo[playerid][pMember] != 8 && PlayerInfo[playerid][pLeader] != 8)
	    {
          SendClientMessage(playerid, COLOR_GREY, "You are not a hitman!");
          return 1;
     	}
    	if (PlayerInfo[playerid][pC4] == 0)
      	{
      	  SendClientMessage(playerid, COLOR_LIGHTRED, "You haven't planted a bomb!");
	      return 1;
    	}
    	CreateExplosion(bx, by, bz, 7, 4);
        PickUpC4(playerid);
     }     
   }
  }
  return 1;
}
Why does it only work when I am at the X Y Z of bomb?
I want it to work if I am anywhere.
Reply


Messages In This Thread
Help me, please. Thanks. - by Austin_Lynn - 04.12.2009, 00:06
Re: Help me, please. Thanks. - by Austin_Lynn - 04.12.2009, 22:08

Forum Jump:


Users browsing this thread: 1 Guest(s)