Ummhhh
#1

Hey,i want to make a command when ya /infect it will take a player near you,atleast 5 meters and infects him/her,but if theres no person near you it wont infect anyone,but im kinda sleepy and i dont see the problem,heres the command

Код:
	if(strcmp(cmd, "/infect", true) == 0)
	{
		for(new i=0;i<MAX_PLAYERS;i++)
		{
			if(i!=playerid)
			{
				new Float:x,Float:y,Float:z;
				GetPlayerPos(playerid,x,y,z);
				if(PlayerToPoint(1,i,x,y,z) && i!=playerid)
				{
					Inftimer = SetTimerEx("InfectedTimer",5000,true,"i",i);
					SendClientMessage(i,COLOR_RED,"You have been biten,you are now infected,Quickly get some antidote");
					Infected[i] = 1;
					new string[256];
					}
					}
					}
	return 1;
	}
Reply


Messages In This Thread
Ummhhh - by WardenCS - 16.12.2010, 15:11
Re: Ummhhh - by WardenCS - 16.12.2010, 17:28
Re: Ummhhh - by Baboon - 16.12.2010, 17:47
Re: Ummhhh - by WardenCS - 17.12.2010, 16:31
Re: Ummhhh - by WillyP - 17.12.2010, 16:35
Re: Ummhhh - by WardenCS - 18.12.2010, 14:11
Re: Ummhhh - by WardenCS - 18.12.2010, 20:25
Re: Ummhhh - by rs.pect - 18.12.2010, 20:41

Forum Jump:


Users browsing this thread: 1 Guest(s)