Register forum user name Search FAQ

Gammon Forum

Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the password reset link.

Due to spam on this forum, all posts now need moderator approval.

 Entire forum ➜ MUSHclient ➜ General ➜ Russerection of an OLD script

Russerection of an OLD script

It is now over 60 days since the last post. This thread is closed.     Refresh page


Posted by David Berthiaume   (202 posts)  Bio
Date Sat 24 Sep 2005 06:46 AM (UTC)
Message
So bacially I found a mud that is almost identical to the old DBZ mud I wrote the autocombo script for. It's slightly different, but more or less the same.

It still has combinations.

Well one of the outputs are:

* is stunned!

Another output is:

* is stunned!
Combination! ( * )

Hence the autocombo code works when matching on the combination line...

However, I tried making a multiline trigger for the combo output, so that it would do the combo. That worked. But I couldn't figure out how to get it to work in conjunction with the rist line, in which I want to throw the mob/player down.

I know it can work, I just don't know how to set it up exactly, what flags for each trigger, and what not... Here is what I have so far.
<triggers>
  <trigger
   enabled="y"
   group="Multi Line"
   ignore_case="y"
   lines_to_match="2"
   keep_evaluating="y"
   match="(.*) is stunned\!\nCombination\! \( (.*) \)\Z"
   multi_line="y"
   regexp="y"
   send_to="2"
   sequence="90"
  >
  <send>Speedwalkdelay = 500
dim AutoCombo
AutoCombo = split ("%2")
Dim i, attack
for i=lbound (AutoCombo ) to ubound (AutoCombo ) 
  Select Case AutoCombo (i) 
    case "rp" attack = "punch right"
    case "lp" attack = "punch left"
    case "sw" attack = "sweep"
    case "r" attack = "roundhouse"
    case "up" attack = "uppercut"
    case "kf" attack = "kickflip"
    case "hm" attack = "hammer"
    case else attack = ""  ' unknown attack type
  End Select          
    Queue attack + " " + world.GetVariable ("attacker"), True
next</send>
  </trigger>
  <trigger
   enabled="y"
   expand_variables="y"
   keep_evaluating="y"
   match="* is stunned"
   send_to="13"
   sequence="90"
  >
  <send>throw @attacker down</send>
  </trigger>
</triggers>
So what order do I need to put these in to work correctly?
Top

Posted by David Berthiaume   (202 posts)  Bio
Date Reply #1 on Sat 24 Sep 2005 07:23 AM (UTC)
Message
Never mind, I solved the problem with a different solution.


I set the plain * is stunned! to queue the command briefly, and I set the Combo trigger to discard the queue when it's set off. Does what I want, that's all I care about.
Top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


12,482 views.

It is now over 60 days since the last post. This thread is closed.     Refresh page

Go to topic:           Search the forum


[Go to top] top

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.