Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on Apr 24th, 2012  |  syntax: None  |  size: 5.98 KB  |  hits: 11  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. <?xml version="1.0" encoding="iso-8859-1"?>
  2. <!DOCTYPE muclient>
  3. <!-- Saved on Sunday, April 17, 2011, 10:00 AM -->
  4. <!-- MuClient version 4.72 -->
  5.  
  6. <!-- Plugin "CompactDmg" generated by Plugin Wizard -->
  7.  
  8. <muclient>
  9. <plugin
  10.    name="CompactDmg"
  11.    author="Red"
  12.    id="0be2c68e848819f3aa46dde8"
  13.    language="Lua"
  14.    purpose="Compacts damage lines"
  15.    date_written="2011-04-17 10:00:00"
  16.    requires="4.72"
  17.    version="1.0"
  18.    >
  19.  
  20. </plugin>
  21. <triggers>
  22.   <trigger
  23.    enabled="y"
  24.    match="^(.+) (spiralling force|hammering blow|frenzied attack|whipping|faith|heavenly balance|wrath of Gaia|eruption) (?:misses|tickles|bruises|scratches|grazes|nicks|scars|hits|injures|wounds|mauls|maims|mangles|mars|LACERATES|DECIMATES|DEVASTATES|ERADICATES|OBLITERATES|EXTIRPATES|INCINERATES|MUTILATES|DISEMBOWELS|MASSACRES|DISMEMBERS|RENDS|- BLASTS -|-= DEMOLISHES =-|\*\* SHREDS \*\*|\*\*\*\* DESTROYS \*\*\*\*|\*\*\*\*\* PULVERIZES \*\*\*\*\*|-=- VAPORIZES -=-|<-==-> ATOMIZES <-==->|<\-\:\-> ASPHYXIATES <\-\:\->|<-\*-> RAVAGES <-\*->|<\*><\*> LIQUIDATES <\*><\*>|<\*><\*><\*> EVAPORATES <\*><\*><\*>|<-=-> SUNDERS <-=->|<=-=><=-=> TEARS INTO <=-=><=-=>|<->\*<=> WASTES <=>\*<->|<-\+-><-\*-> CREMATES <-\*-><-\+->|<\*><\*><\*><\*> ANNIHILATES <\*><\*><\*><\*>|<--\*--><--\*--> IMPLODES <--\*--><--\*-->|<-><-=-><-> EXTERMINATES <-><-=-><->|<-==-><-==-> SHATTERS <-==-><-==->|<\*><-:-><\*> SLAUGHTERS <\*><-:-><\*>|<-\*-><-><-\*-> RUPTURES <-\*-><-><-\*->|<-\*-><\*><-\*-> NUKES <-\*-><\*><-\*->|-<\[=-\+-=\]<:::<>:::> GLACIATES <:::<>:::>\[=-\+-=\]>-|<-=-><-:-\*-:-><\*--\*> METEORITES <\*--\*><-:-\*-:-><-=->|<-:-><-:-\*-:-><-\*-> SUPERNOVAS <-\*-><-:-\*-:-><-:->|does UNSPEAKABLE things to|does UNTHINKABLE things to|does UNIMAGINABLE things to|does UNBELIEVABLE things to|pimpslaps|<>\*<> FISSURES <>\*<>) (.+) \[(\d+)\]$"
  25.    regexp="y"
  26.    name="CombatRoundtrig"
  27.    script="CombatRound"
  28.    keep_evaluating="n"
  29.    omit_from_output="y"
  30.    sequence="110"
  31.   > </trigger>
  32.     <trigger
  33.    enabled="n"
  34.    match="*"
  35.    name="NotCombatRound"
  36.    script="CombatRoundEnd"
  37.    omit_from_output="y"
  38.    keep_evaluating="y"
  39.    sequence="120"
  40.   > </trigger>
  41. </triggers>
  42. <aliases>
  43.    <alias
  44.    match="^testverb (.*)$"
  45.    regexp="y"
  46.    enabled="y"
  47.    script="testverb"
  48.    sequence="100"
  49.   >
  50.   </alias>  
  51.  </aliases>
  52.  
  53. <!--  Get our standard constants -->
  54.  
  55. <include name="constants.lua"/>
  56. <script>
  57. <![CDATA[
  58. --match="^(.*)$"
  59. --match="^((?!.+ (?:hammering blow|frenzied attack|whipping|faith|heavenly balance|wrath of Gaia|eruption) (?:misses|tickles|bruises|scratches|grazes|nicks|scars|hits|injures|wounds|mauls|maims|mangles|mars|LACERATES|DECIMATES|DEVASTATES|ERADICATES|OBLITERATES|EXTIRPATES|INCINERATES|MUTILATES|DISEMBOWELS|MASSACRES|DISMEMBERS|RENDS|- BLASTS -|-= DEMOLISHES =-|\*\* SHREDS \*\*|\*\*\*\* DESTROYS \*\*\*\*|\*\*\*\*\* PULVERIZES \*\*\*\*\*|-=- VAPORIZES -=-|<-==-> ATOMIZES <-==->|<\-\:\-> ASPHYXIATES <\-\:\->|<-\*-> RAVAGES <-\*->|<\*><\*> LIQUIDATES <\*><\*>|<\*><\*><\*> EVAPORATES <\*><\*><\*>|<-=-> SUNDERS <-=->|<=-=><=-=> TEARS INTO <=-=><=-=>|<->\*<=> WASTES <=>\*<->|<-\+-><-\*-> CREMATES <-\*-><-\+->|<\*><\*><\*><\*> ANNIHILATES <\*><\*><\*><\*>|<--\*--><--\*--> IMPLODES <--\*--><--\*-->|<-><-=-><-> EXTERMINATES <-><-=-><->|<-==-><-==-> SHATTERS <-==-><-==->|<\*><-:-><\*> SLAUGHTERS <\*><-:-><\*>|<-\*-><-><-\*-> RUPTURES <-\*-><-><-\*->|<-\*-><\*><-\*-> NUKES <-\*-><\*><-\*->|-<\[=-\+-=\]<:::<>:::> GLACIATES <:::<>:::>\[=-\+-=\]>-|<-=-><-:-\*-:-><\*--\*> METEORITES <\*--\*><-:-\*-:-><-=->|<-:-><-:-\*-:-><-\*-> SUPERNOVAS <-\*-><-:-\*-:-><-:->|does UNSPEAKABLE things to|does UNTHINKABLE things to|does UNIMAGINABLE things to|does UNBELIEVABLE things to|pimpslaps|<>\*<> FISSURES <>\*<>) (?:.+) \[(?:\d+)\]).)*$"
  60. require "damverbs"
  61.  
  62. function testverb(name,line,wildcards)
  63. ColourTell("silver","black",wildcards[1].." ")
  64. OutputDamverb(tonumber(wildcards[1]))
  65. Note("")
  66. end
  67.  
  68. Rounds = 0
  69. Target = ""
  70. User = ""
  71. Skilltype = ""
  72. DamageDone = 0
  73.  
  74. function CombatRound (name,line,wildcards)
  75.         EnableTrigger("NotCombatRound",true)
  76.         if wildcards[1]~=User and User~="" then
  77.                 CombatRoundEnd()
  78.         else
  79.                 User = wildcards[1]
  80.         end
  81.         if wildcards[2]~=Skilltype and Skilltype~="" then
  82.                 CombatRoundEnd()
  83.         else   
  84.                 Skilltype=wildcards[2]
  85.         end
  86.         if Target=="" then
  87.                 Target = wildcards[3]
  88.         elseif not string.find(Target,string.sub(string.clean(wildcards[3]),1,-2)) then
  89.                 Target = string.sub(Target,1,-2)..","..wildcards[3]
  90.         end
  91.         DamageDone = DamageDone+wildcards[4]
  92.         Rounds = Rounds+1
  93. end
  94.  
  95. function CombatRoundEnd(name,line,wildcards,styles)
  96. if wildcards then
  97.    if string.find(wildcards[1],"is not in the direct line of your charge.") then
  98.       misscharge=1
  99.       if styles then
  100.          for _, v in ipairs (styles) do
  101.                ColourTell (RGBColourToName (v.textcolour),RGBColourToName (v.backcolour),v.text)
  102.          end
  103.          Note ("")
  104.       end
  105.       return
  106.    end
  107.    if string.find(wildcards[1],"fades into existence.") then
  108.       if styles then
  109.          for _, v in ipairs (styles) do
  110.                ColourTell (RGBColourToName (v.textcolour),RGBColourToName (v.backcolour),v.text)
  111.          end
  112.          Note ("")
  113.       end
  114.       return
  115.    end
  116. end
  117.         if User=="Your" then
  118.                 linecolour="lime"
  119.         elseif Target=="you!" or Target=="you." then
  120.                 linecolour="red"
  121.         else
  122.                 linecolour="silver"
  123.         end
  124.         ColourTell(linecolour,"black","["..Rounds.."] "..User.." "..Skilltype.." ")
  125.         OutputDamverb(DamageDone)
  126.         ColourTell(linecolour,"black"," "..Target.." ","red","black","["..DamageDone.."] ["..string.format( "%.0f",DamageDone/Rounds).."]")
  127.         Note("")
  128.         if styles then
  129.                 for _, v in ipairs (styles) do
  130.                                 ColourTell (RGBColourToName (v.textcolour),RGBColourToName (v.backcolour),v.text)
  131.                 end
  132.                 Note ("")
  133.         end
  134.    if misscharge==1 then
  135.       Send("c 84")
  136.       misscharge=0
  137.    end
  138.         EnableTrigger("NotCombatRound",false)
  139.         Rounds = 0
  140.         Target = ""
  141.         User = ""
  142.         Skilltype = ""
  143.         DamageDone = 0
  144. end
  145.  
  146. function string.clean(s)
  147. s = string.gsub(s,'%-','%%-')
  148. return s
  149. end
  150.  
  151. ]]>
  152. </script>
  153. </muclient>