|  | 
	
	
		| Twigg Wanderer
 
 
 Joined: 22 May 2003
 Posts: 60
 Location: USA
 
 | 
			
			  |  Posted: Mon Jun 21, 2004 4:53 am 
 #ALARM;#ALARM;#ALARM;...still don' quite have it
 
 |  
				| Alright, What is wrong with this ALIAS? I thought I had it and now...is it something with my spacing?
 
 #ALIAS lhome {unlock door;#ALARM +1 {open door;#ALARM +1 {go door; #ALARM +1 {close door;#ALARM +1 {lock door;#ALARM +1 {out;#ALARM +{down;#ALARM +1 {out}}}}}}}}
 Once again, Thank-you
 |  | 
	
	  |  | 
	
		|  | 
	
		| LightBulb MASTER
 
 
 Joined: 28 Nov 2000
 Posts: 4817
 Location: USA
 
 | 
			
			  |  Posted: Mon Jun 21, 2004 5:56 am 
 |  
				| You left out the number for the sixth alarm. There is also an unneeded space before the third alarm. #ALIAS lhome {unlock door;#ALARM +1 {open door;#ALARM +1 {go door; #ALARM +1 {close door;#ALARM +1 {lock door;#ALARM +1 {out;#ALARM +{down;#ALARM +1 {out}}}}}}}}
 
 I would probably redo the alias so the alarms weren't nested.
 #ALIAS lhome {unlock door;#ALARM +1 {open door};#ALARM +2 {go door};#ALARM +3 {close door};#ALARM +4 {lock door};#ALARM +5 {out};#ALARM +6 {down};#ALARM +7 {out}}
 |  | 
	
	  |  | 
	
		|  | 
	
		| Twigg Wanderer
 
 
 Joined: 22 May 2003
 Posts: 60
 Location: USA
 
 | 
			
			  |  Posted: Mon Jun 21, 2004 3:03 pm 
 |  
				| Lightbulb, thanks, I am delighted that I almost had it right! Interesting that the script can be written with the #ALARMs nested or put the actions in brackets.  Can this be done with any simple script of this type instead of nesting the #ALARM command?
 Once again thank-you for helping me sort this out!
 Wait a minute....I just took a good look at the #AlIAS correction you sent...this is they way I understand it.  If the #ALARM is embedded then each additional #ALARM time can be unique..not accrue.  If it is not embedded then each additional #ALARM time amounts adds on to the next one?  Yes?
 |  | 
	
	  |  | 
	
		|  | 
	
		| geniusclown Magician
 
  
 Joined: 23 Apr 2003
 Posts: 358
 Location: USA
 
 | 
			
			  |  Posted: Mon Jun 21, 2004 3:19 pm 
 |  
				| As you learn the nuances of zMUD, you'll find that there are multiple ways of doing just about anything.  Another option for this script would be to set itup as a multistate trigger, and it may work a little quicker and more reliably.  For the sake of example, I'll just assume what you see at each step, and also assume that room names appear in []. 
 Start by unlocking the door manually.
 
 quote:
 #TR {You unlock the door} {open door}
 #COND {You open the door} {go door}
 #COND {~[Your home~]} {close door}
 #COND {You close the door} {lock door}
 #COND {You lock the door} {out}
 #COND {~[Outside your home~]} {down}
 #COND {~[Outside and below your home~]} {out}
 
 
 |  | 
	
	  |  | 
	
		|  | 
	
		| Twigg Wanderer
 
 
 Joined: 22 May 2003
 Posts: 60
 Location: USA
 
 | 
			
			  |  Posted: Mon Jun 21, 2004 3:26 pm 
 |  
				| Geniusclown, what I want to know is if the way you have it written is the way I would enter it on the command line? (love command line entry!)  I mean I understand that I supply the correct triggers...I am wild to learn how to use triggers and the best way for me to learn how to do it, is to make one that works...
 |  | 
	
	  |  | 
	
		|  | 
	
		| Mercator Newbie
 
 
 Joined: 05 May 2004
 Posts: 7
 Location: United Kingdom
 
 | 
			
			  |  Posted: Mon Jun 21, 2004 4:07 pm 
 |  
				| The trigger that Genuisclown provided is for command line entry although you'll probably need to seperate all your conditions with a ; 
 |  | 
	
	  |  | 
	
		|  | 
	
		| Twigg Wanderer
 
 
 Joined: 22 May 2003
 Posts: 60
 Location: USA
 
 | 
			
			  |  Posted: Mon Jun 21, 2004 4:58 pm 
 |  
				| Mercator. Like this?
 
 #TR;{You unlock the door} {open door}
 #COND;{You open the door} {go door}
 #COND;{~[Your home~]} {close door}
 #COND;{You close the door} {lock door}
 #COND;{You lock the door} {out}
 #COND;{~[Outside your home~]} {down}
 #COND;{~[Outside and below your home~]} {out}
 |  | 
	
	  |  | 
	
		|  | 
	
		| mr_kent Enchanter
 
 
 Joined: 10 Oct 2000
 Posts: 698
 
 
 | 
			
			  |  Posted: Mon Jun 21, 2004 5:39 pm 
 |  
				| #TR {You unlock the door} {open door}; #COND {You open the door} {go door};#COND {~[Your home~]} {close door};
 #COND {You close the door} {lock door};
 #COND {You lock the door} {out};
 #COND {~[Outside your home~]} {down};
 #COND {~[Outside and below your home~]} {out};
 
 Is what he meant, but if you copy, paste (and edit-to match the lines received-) the block, then the semicolons aren't needed.
 
 Semicolons would be needed if there were no hard returns in the block after pasting... for example:
 
 #TR {You unlock the door} {open door};#COND {You open the door} {go door};#COND {~[Your home~]} {close door};#COND {You close the door} {lock door};#COND {You lock the door} {out};#COND {~[Outside your home~]} {down};#COND {~[Outside and below your home~]} {out}
 |  | 
	
	  |  | 
	
		|  | 
	
		| Mercator Newbie
 
 
 Joined: 05 May 2004
 Posts: 7
 Location: United Kingdom
 
 | 
			
			  |  Posted: Mon Jun 21, 2004 8:00 pm 
 |  
				| Thanks for the explanation mr_kent. Twigg is going to be making many, many command line multi-state triggers really soon :) 
 |  | 
	
	  |  | 
	
		|  | 
	
		| Twigg Wanderer
 
 
 Joined: 22 May 2003
 Posts: 60
 Location: USA
 
 | 
			
			  |  Posted: Mon Jun 21, 2004 10:13 pm 
 |  
				| Yes indeed! Twigg is delighted...I have not tried to make a trigger yet but I am far closer to understanding how to do it! Thank-you!
 |  | 
	
	  |  | 
	
		|  | 
	
		|  | 
	
		|  |