Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD General Discussion
albo
Apprentice


Joined: 27 Mar 2008
Posts: 106

PostPosted: Sat Oct 01, 2011 4:53 pm   

I have forgotten how to make a multistate trigger!!
 
The first state..
Code:
<trigger priority="39840" id="3984">
  <pattern>Arcanum  is resting on the ground</pattern>
  <value>#t- korerunskill
#t- korerunswalk
#suspend korerunsbot</value>
</trigger>


And this is what I need to happen once he stand up.
Code:
<trigger priority="39850" id="3985">
  <pattern>Arcanum stands up</pattern>
  <value>#t+ korerunskill
#t+ korerunswalk
look</value>
</trigger>
Reply with quote
Stowslee
Wanderer


Joined: 20 Apr 2008
Posts: 69
Location: Watervliet, NY

PostPosted: Sat Oct 01, 2011 5:10 pm   
 
Personally I use #TEMP instead of multi-state triggers. My solution to that particular code would be:

Code:

<trigger priority="39840" id="2288">
  <pattern>Arcanum  is resting on the ground</pattern>
  <value>#t- korerunskill
#t- korerunswalk
#suspend korerunsbot
#TEMP {Arcanum stands up} {#t+ korerunskill;#t+ korerunswalk;look}</value>
</trigger>


For what I do, works just fine for me. Not sure if there are advantages/disadvantages to using one over the other.
Reply with quote
Daern
Sorcerer


Joined: 15 Apr 2011
Posts: 809

PostPosted: Sat Oct 01, 2011 5:52 pm   
 
In the package editor, click on the trigger you want to add another state to, then click new at the top and choose new trigger state. In xml, your triggers above would look like this:
Code:
<?xml version="1.0" encoding="ISO-8859-1" ?>
<cmud>
  <trigger priority="32560" copy="yes">
    <pattern>Arcanum  is resting on the ground</pattern>
    <value>#t- korerunskill
#t- korerunswalk
#suspend korerunsbot</value>
    <trigger>
      <pattern>Arcanum stands up</pattern>
      <value>#t+ korerunskill
#t+ korerunswalk
look</value>
    </trigger>
  </trigger>
</cmud>

To Stowslee: repeatedly creating and deleting triggers is much less efficient than just keeping the triggers made and enabling and disabling them as necessary. In general, #temp should only be used for things that really do only need to fire once ever.
Reply with quote
albo
Apprentice


Joined: 27 Mar 2008
Posts: 106

PostPosted: Sat Oct 01, 2011 6:49 pm   
 
Yeah, i just stuck with the multistate trigger.

#temp is fine, and is going to be used in a trigger for a buff that won't re-cast if i'm in battle. So I will use the pattern telling me I'm in battle when I try to cast it to create a #temp trigger to cast it when the battle is over with and I receive exp.

The website acts like a stupid red headed step child bitch from time to time and i get frustrated having to log in every time I click a mother effin link here and so it did not post my statement on how I found out how to create a multistate trigger by looking it up in the cmud manual.
Reply with quote
MattLofton
GURU


Joined: 23 Dec 2000
Posts: 4834
Location: USA

PostPosted: Sat Oct 01, 2011 7:26 pm   
 
The advantage of using a multistate trigger is that the firing of the lines can never, ever, get out of order unless you use #SET or #STATE.

Quote:

The website acts like a stupid red headed step child bitch from time to time and i get frustrated having to log in every time I click a mother effin link here and so it did not post my statement on how I found out how to create a multistate trigger by looking it up in the cmud manual.


On the first part, when you type in your login info make sure to check the Remember Me checkbox immediately below the login button (seriously, you're blind if you don't see it.) Beyond that, it's an issue with your security suite settings or the fact that your computer is going into hibernation or similar situation, which causes all your outside connections and stuff like cookies to be flushed (I don't recall XP doing this, so maybe it's just a Vista/Win7 thing).

On the second part, do tell. I can't tell if you are shocked that you had to go looking in a help file to get a question answered or if you are praising Zugg for a job well done (at least on that particular help topic).
_________________
EDIT: I didn't like my old signature
Reply with quote
albo
Apprentice


Joined: 27 Mar 2008
Posts: 106

PostPosted: Sat Oct 01, 2011 7:48 pm   
 
Not shocked at all, Daern was quickly responding to my topics and I had the problem with the trigger so I posted it while also deciding to check out the manual and I found the answer to my question very quickly.

I just couldn't post that I found the answer with the solution code because I when I typed everything out (while logged in) and hit submit and was asked to log in again I got very frustrated.

During all this adding to my frustration was a piece of code/trigger that suddenly decided to act up!

I apologize if I got out of line or anything..
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net