[Home] [Downloads] [Search] [Help/forum]

Gammon Forum

See www.mushclient.com/spam for dealing with forum spam. Please read the MUSHclient FAQ!

[Folder]  Entire forum
-> [Folder]  MUSHclient
. -> [Folder]  Plugins
. . -> [Subject]  Aardwolf Consider Plugin (fixed)
Home  |  Users  |  Search  |  FAQ
Username:
Register forum user name
Password:
Forgotten password?

Aardwolf Consider Plugin (fixed)

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


Posted by Amigan   (2 posts)  [Biography] bio
Date Wed 19 May 2010 09:34 PM (UTC)
Message
Due to changes in how flags are displayed on mobs, some of the matches in this consider plugin were broken, I've simply added wildcards to restore this plugin to its former glory :)

Save as Consider_info.xml



<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE muclient>
<!-- Saved on Wednesday, August 06, 2008, 1:13 PM -->
<!-- MuClient version 4.35 -->

<!-- Plugin "Consider_info" generated by Plugin Wizard -->

<muclient>
<plugin
   name="Consider_info"
   author="Nick Gammon"
   id="2a5caa1cd7dbcff665e2a23d"
   language="Lua"
   purpose="Colours &quot;consider&quot; lines"
   date_written="2008-10-15 07:35"
   requires="4.30"
   version="2.0"
   >
<description trim="y">
<![CDATA[
When you type "consider" (or "consider all") the lines are coloured to make it easier to tell high level from low level mobs.
]]>
</description>

</plugin>


<!--  Triggers  -->

<triggers>

  <trigger
   enabled="y"
   group="consider"
   match="*You would stomp * into the ground."
   omit_from_output="y"
   script="adapt_consider"
   sequence="100"
   name="a"
  >
  </trigger>

  <trigger
   enabled="y"
   group="consider"
   match="* would be easy, but is it even worth the work out?"
   omit_from_output="y"
   script="adapt_consider"
   sequence="100"
   name="b"
  >
  </trigger>
  
  <trigger
   enabled="y"
   group="consider"
   match="*No Problem! * is weak compared to you."
   omit_from_output="y"
   script="adapt_consider"
   sequence="100"
   name="c"
  >
  </trigger>
  
  <trigger
   enabled="y"
   group="consider"
   match="* looks a little worried about the idea."
   omit_from_output="y"
   script="adapt_consider"
   sequence="100"
   name="d"
  >
  </trigger>

  <trigger
   enabled="y"
   group="consider"
   match="* should be a fair fight!"
   omit_from_output="y"
   script="adapt_consider"
   sequence="100"
   name="e"
  >
  </trigger>

  <trigger
   enabled="y"
   group="consider"
   match="* snickers nervously."
   omit_from_output="y"
   script="adapt_consider"
   sequence="100"
   name="f"
  >
  </trigger>
  
  <trigger
   enabled="y"
   group="consider"
   match="^(.*?) chuckles at the thought of you fighting (him|her|it)\.$"
   omit_from_output="y"
   regexp="y"
   script="adapt_consider"
   sequence="100"
   name="g"
  >
  </trigger>
    
  <trigger
   enabled="y"
   group="consider"
   match="*Best run away from * while you can!"
   omit_from_output="y"
   script="adapt_consider"
   sequence="100"
   name="h"
  >
  </trigger>
  
  <trigger
   enabled="y"
   group="consider"
   match="*Challenging * would be either very brave or very stupid."
   omit_from_output="y"
   script="adapt_consider"
   sequence="100"
   name="i"
  >
  </trigger>
  
  <trigger
   enabled="y"
   group="consider"
   match="* would crush you like a bug!"
   omit_from_output="y"
   script="adapt_consider"
   sequence="100"
   name="j"
  >
  </trigger>
  
  <trigger
   enabled="y"
   group="consider"
   match="* would dance on your grave!"
   omit_from_output="y"
   script="adapt_consider"
   sequence="100"
   name="k"
  >
  </trigger>
  
  <trigger
   enabled="y"
   group="consider"
   match="* says 'BEGONE FROM MY SIGHT unworthy!'"
   omit_from_output="y"
   script="adapt_consider"
   sequence="100"
   name="l"
  >
  </trigger>
 
  <trigger
   enabled="y"
   group="consider"
   match="*You would be completely annihilated by *!"
   omit_from_output="y"
   script="adapt_consider"
   sequence="100"
   name="m"
  >
  </trigger>
  
</triggers>

<!--  Script  -->


<script>
<![CDATA[

consider_messages = {
    a = { range = "-19 and below",  colour = "gray", },
    b = { range = "-10 to -19",     colour = "darkgreen", },
    c = { range = "-6 to -9",       colour = "forestgreen", },
    d = { range = "-2 to -6",       colour = "chartreuse", },
    e = { range = "-2 to +2",       colour = "springgreen", },
    f = { range = "+2 to +3",       colour = "darkgoldenrod", },
    g = { range = "+3 to +8",       colour = "gold", },
    h = { range = "+8 to +16",      colour = "tomato", },
    i = { range = "+16 to +21",     colour = "crimson", },
    j = { range = "+21 to +32",     colour = "lightpink", },
    k = { range = "+32 to +41",     colour = "darkmagenta", },
    l = { range = "+41 to +50",     colour = "darkviolet", },
    m = { range = "+50 and above",  colour = "magenta", },
      } -- end of consider_messages
      
function adapt_consider (name, line, wildcards)
  mob = consider_messages [name]
  if mob then
    ColourNote (mob.colour, "", line .. " (" .. mob.range .. ")" )
  else
    ColourNote ("white", "blue", "Could not find message for trigger: " .. line)
  end -- if
end -- adapt_consider

]]>
</script>

</muclient>
[Go to top] 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.


2,672 views.

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

Go to topic:           Search the forum


[Go to top] top

Quick links: MUSHclient. MUSHclient help. Forum shortcuts. Posting templates. Lua modules. Lua documentation.

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

[Home]


Written by Nick Gammon - 5K   profile for Nick Gammon on Stack Exchange, a network of free, community-driven Q&A sites   Marriage equality

Comments to: Gammon Software support
[RH click to get RSS URL] Forum RSS feed ( https://gammon.com.au/rss/forum.xml )

[Best viewed with any browser - 2K]    [Hosted at FutureQuest]