SA-MP Forums Archive
anti hydra zone - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: anti hydra zone (/showthread.php?tid=143700)



anti hydra zone - BLAbla93 - 24.04.2010

well i made this

Код:
else if(newkeys & KEY_FIRE)
  	{
  	  new Float:x, Float:y, Float:z;
		if (GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
		{
		  if (GetVehicleModel(GetPlayerVehicleID(playerid)) == 520)
		  {
		    if((x > -221.8796) && (x < 525.5044) && (y > 2382.287) && (y < 2592.488))
		    {
		      SetPlayerPos(playerid, x, y, z+40);
		      GivePlayerWeapon(playerid, 11, 1);
					return 1;
				}
			}
		}
	}
but the problem is when i goto the abandoned air yard to test it it does not work D=


Re: anti hydra zone - Correlli - 24.04.2010

You're not getting the position of the player, use this - https://sampwiki.blast.hk/wiki/GetPlayerPos


Re: anti hydra zone - _Vortex - 24.04.2010

another problem would be this:
Код:
if((x > -221.8796) && (x < 525.5044) && (y > 2382.287) && (y < 2592.488))
Wouldn't you need to be at those EXACT coordinates for your setplayerpos to be called?...


Re: anti hydra zone - BLAbla93 - 24.04.2010

no becuase its using greater then less then symbols instead of ==

and lol forgot the most simple part xD