Damascus 
 
 
		
			Senior Member 
			
			
			
 
			
	Posts: 646 
	Threads: 118 
	Joined: Mar 2012
	
 Reputation: 
29
		
	 | 
	
		
			
Multiple "if" statement 
			 
			
				I scoured the wiki but I still can't find the tutorial on "if" statements, so I'll just ask it here: 
 
How do I get a script to activate only when multiple "if's" are satisfied? I want to trigger a function, for example, when a certain variable is at 1 and when two entities are inside certain script areas. 
			 
			
			
 
			
				
(This post was last modified: 03-30-2012, 12:08 AM by Damascus.)
 
				
			 
		 |  
	 
 | 
	| 03-29-2012, 07:03 AM  | 
	
		
	 | 
	
		
		SilentStriker 
 
 
		
			Posting Freak 
			
			
			
 
			
	Posts: 950 
	Threads: 26 
	Joined: Jul 2011
	
 Reputation: 
43
		
	 | 
	
		
			
RE: Multiple "if" statement 
			 
			
				well the way I know is you use something like this: 
 
if(GetLocalVarInt(jfjeb) == 1 && GetLocalVarInt(hello) == 1) 
{ 
 
}
			 
			
			
 
			
		 |  
	 
 | 
	| 03-29-2012, 07:23 AM  | 
	
		
	 | 
	
		
		Damascus 
 
 
		
			Senior Member 
			
			
			
 
			
	Posts: 646 
	Threads: 118 
	Joined: Mar 2012
	
 Reputation: 
29
		
	 | 
	
		
			
RE: Multiple "if" statement 
			 
			
				Worked like a charm. Thanks man! 
			 
			
			
 
			
		 |  
	 
 | 
	| 03-30-2012, 12:08 AM  | 
	
		
	 | 
	
		
		SilentStriker 
 
 
		
			Posting Freak 
			
			
			
 
			
	Posts: 950 
	Threads: 26 
	Joined: Jul 2011
	
 Reputation: 
43
		
	 | 
	
		
			
RE: Multiple "if" statement 
			 
			
				You're welcome   
			 
			
			
 
			
		 |  
	 
 | 
	| 03-30-2012, 06:20 AM  | 
	
		
	 |