FreshKorruption 
 
 
		
			Member 
			
			
			
 
			
	Posts: 94 
	Threads: 27 
	Joined: Oct 2011
	
 Reputation: 
1
		
	 | 
	
		
			
Area that kills player? 
			 
			
				In one of my maps, I want it so when you hit the ground (which is also going to be an area) it kills you. Because the fall damage enough isn't going to finish you off.
			 
			
			
 
			
		 |  
	 
 | 
	| 01-05-2012, 04:55 AM  | 
	
		
	 | 
	
		
		Statyk 
 
 
		
			Schrödinger's Mod 
			
			
			
 
			
	Posts: 4,390 
	Threads: 72 
	Joined: Sep 2011
	
 Reputation: 
241
		
	 | 
	
		
			
RE: Area that kills player? 
			 
			
				Make an area surrounding the bottom and name it "deathzone" Then add these with your info where necessary: 
 
void OnStart() 
{ 
AddEntityCollideCallback("Player", "deathzone", "killplayer_func", false, 1); 
} 
 
 
void killplayer_func(string &in asParent, string &in asChild, int alState) 
{ 
SetPlayerHealth(0); 
}
			 
			
			
			
		 |  
	 
 | 
	| 01-05-2012, 05:00 AM  | 
	
		
	 | 
	
		
		FreshKorruption 
 
 
		
			Member 
			
			
			
 
			
	Posts: 94 
	Threads: 27 
	Joined: Oct 2011
	
 Reputation: 
1
		
	 | 
	
		
			
RE: Area that kills player? 
			 
			
				 (01-05-2012, 05:00 AM)Statyk Wrote:  Make an area surrounding the bottom and name it "deathzone" Then add these with your info where necessary: 
 
void OnStart() 
{ 
AddEntityCollideCallback("Player", "deathzone", "killplayer_func", false, 1); 
} 
 
 
void killplayer_func(string &in asParent, string &in asChild, int alState) 
{ 
SetPlayerHealth(0); 
} Thanks once again. lol 
			  
			
			
 
			
		 |  
	 
 | 
	| 01-05-2012, 05:11 AM  | 
	
		
	 |