Gates Bugged? HELP Please :D
#1

So, i have 2 gates for my Clan base in my server but they only work for 1 player (the last TT member or the first that joins the server)


Код:
public gatefront()
{
	for(new i=0;i<MAX_PLAYERS; i++)
	{
	  new PlayerName[24];
  		GetPlayerName(i, PlayerName, sizeof(PlayerName));
  		if(strfind(PlayerName[i], "[TT]", false) != -1)
		{
			if (PlayerToPoint(10.0, i,1970.0643,1764.3062,12.7157 ) && FrontGate_status == 0)
			{
				MoveObject(gatefront1, 1969.4080810547, 1761.0424804688, 17.521432876587,3);
				MoveObject(gatefront2, 1969.4031982422, 1767.6744384766, 17.521432876587,3);
				FrontGate_status = 1;
			}
			else if (!PlayerToPoint(10.0, i,1970.0643,1764.3062,12.7157 ) && FrontGate_status == 1)
			{
				MoveObject(gatefront1, 1969.4080810547, 1761.0424804688, 14.521432876587,3);
				MoveObject(gatefront2, 1969.4031982422, 1767.6744384766, 14.521432876587,3);
  				FrontGate_status = 0;
			}
		}
	}
}
public gateback()
{
	for(new i=0;i<MAX_PLAYERS; i++)
	{
		new PlayerName[24];
		GetPlayerName(i, PlayerName, sizeof(PlayerName));
	  if(strfind(PlayerName[i], "[TT]", false) != -1)
		{
			if (PlayerToPoint(10.0, i,1918.0104,1969.7140,7.5938) && BackGate_status == 0)
			{
				MoveObject(gateback1,1917.3553466797, 1973.0606689453, 12.3714904785156,3);
				MoveObject(gateback2,1917.3598632813, 1966.2652587891, 12.3723287582397,3);
				BackGate_status = 1;
			}
			else if (!PlayerToPoint(10.0, i,1918.0104,1969.7140,7.5938) && BackGate_status == 1)
			{
				MoveObject(gateback1,1917.3553466797, 1973.0606689453, 9.3714904785156,3);
				MoveObject(gateback2,1917.3598632813, 1966.2652587891, 9.3723287582397,3);
  				BackGate_status = 0;
			}
		}
	}
}
Can anyone please help me? i want them to open for ALL TT members if they are in a range of 10 [meters] and i have no idea how to fix it...

if you need more info, just say
Ofcourse i defined everything as it shud be, i have no warnings/errors in my filterscript [yes its a filterscript]
Reply


Messages In This Thread
Gates Bugged? HELP Please :D - by doggeh - 05.05.2010, 10:06
Re: Gates Bugged? HELP Please :D - by Andy_McKinley - 05.05.2010, 10:40
Re: Gates Bugged? HELP Please :D - by doggeh - 05.05.2010, 12:01
Re: Gates Bugged? HELP Please :D - by doggeh - 07.05.2010, 16:29
Re: Gates Bugged? HELP Please :D - by Conroy - 07.05.2010, 17:07
Re: Gates Bugged? HELP Please :D - by doggeh - 07.05.2010, 19:01
Re: Gates Bugged? HELP Please :D - by Conroy - 07.05.2010, 19:29
Re: Gates Bugged? HELP Please :D - by doggeh - 07.05.2010, 20:00
Re: Gates Bugged? HELP Please :D - by dice7 - 07.05.2010, 20:18
Re: Gates Bugged? HELP Please :D - by Conroy - 07.05.2010, 20:48

Forum Jump:


Users browsing this thread: 1 Guest(s)