Announcement

Collapse
No announcement yet.

Auto Sippers

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Auto Sippers

    Thought I'd start a thread to share my auto sipper set up, and to check out everyone elses and see how they very and whatnot person to person, and client to client. Added descriptions.... probably just confused everyone, and made a mess of it.

    The top two triggers here are basically the same. The first one, ALWAYS fires. It sets the HP variables again, which I only actually use one of here. Then, if my hp is over 2900(the point i heal at) it turns on the second trigger which is the same but with a lower sequence so it fires first on the next prompt. It also turns of autohealth, just to be sure. Otherwise it turns on autohealth to be sure.
    Code:
    <triggers>
      <trigger
       enabled="y"
       match="^(.*?)\/(.*?)h (.*?)\/(.*?)m \&gt; $"
       send_to="12"
       sequence="100"
      >
      <send>SetVariable ("hp", "%1")
    SetVariable ("hpMax", "%2")
    if @hp > 2900 then
    EnableTriggerGroup ("prompthealth", true)
    EnableTriggerGroup ("autohealth", false)
    else
    EnableTriggerGroup ("autohealth", false)
    end</send>
      </trigger>
    </triggers>
    Code:
    <triggers>
      <trigger
       enabled="y"
       expand_variables="y"
       group="prompthealth"
       match="^(.*?)\/(.*?)h (.*?)\/(.*?)m \&gt; $"
       regexp="y"
       send_to="12"
       sequence="99"
      >
      <send>SetVariable ("hp", "%1")
    SetVariable ("hpMax", "%2")
    if @hp > 2900 then
    EnableTriggerGroup ("autohealth", false)
    else
    EnableTriggerGroup ("autohealth", true)
    if @healthbalance == 1 then
    Send ("sip blood")
    SetVariable ("healthbalance", "2")
    end
    end</send>
      </trigger>
    </triggers>
    The above trigger gets turned on when off from the first trigger. To be sure, if my health is over 2900 it turns off the autohealth, otherwise it turns on autohealth, checks my health sip balance and if its good to go, sips blood, and sets the balance to 2 which is unbalanced.

    The trigger below is autohealth. It is what does most of the sipping. First off it always sets my health balance to true, or balanced, or 1 meaning I can sip again. Then it checks my health to see if im above the autohealth limit, and if im health balanced. If I am both then it turns off autohealth, and turns the prompthealth above back on. Otherwise it sips blood again, and sets health balance to 2, unbalanced.
    Code:
    <triggers>
      <trigger
       custom_colour="7"
       expand_variables="y"
       group="autohealth"
       match="*You may consume more blood now.*"
       send_to="12"
       sequence="80"
      >
      <send>SetVariable ("healthbalance", "1")
    if @hp > 2899 and @healthbalance == 1 then
    EnableTriggerGroup ("autohealth", false)
    EnableTriggerGroup ("prompthealth", true)
    else
    Send ("sip blood")
    SetVariable ("healthbalance", "2")
    end
    </send>
      </trigger>
    </triggers>
    This is what is fired, when my health is above 2900, and I regain health balance.
    Code:
    <triggers>
      <trigger
       custom_colour="7"
       enabled="y"
       group="hcolor"
       match="*You may consume more blood now.*"
       send_to="12"
       sequence="100"
      >
      <send>SetVariable ("healthbalance", "1")</send>
      </trigger>
    </triggers>
    This makes sure, I can't oversip, just to be sure.
    Code:
    <triggers>
      <trigger
       enabled="y"
       group="healthbalance"
       match="*The blood courses through you, strengthening your resolve.*"
       send_to="12"
       sequence="100"
      >
      <send>SetVariable ("healthbalance", "2")</send>
      </trigger>
    </triggers>
    Last edited by Jaquen; 6 January 2016, 08:34 PM.

  • #2
    MUSHClient, ey? I'll drop mine in a bit, for Mudlet. It's simple but it does well. It tracks bal/focus for command queuing (other script), as well as displaying changes to vitals. Flags (also another script) are a top-off for my old system that would show important things, like the presence of the dodge defense, Intonation Sprite, Stigmata, etc. Just handy stuff.

    Match:
    Code:
    ^(\d+)\/(\d+)h (\d+)\/(\d+)m (\d+)xp (f)?(u)?
    Script:
    Code:
    health=tonumber(matches[2])
    maxhealth=tonumber(matches[3])
    siphealth=(maxhealth*0.85)
    eathealth=(maxhealth*0.72)
    mana=tonumber(matches[4])
    maxmana=tonumber(matches[5])
    sipmana=(maxmana*0.65)
    
    deltahealth=health-lasthealth
    lasthealth=health
    deltamana=mana-lastmana
    lastmana=mana
    
    if deltahealth < 0 and vitalspam==true then
     cecho("<red>("..deltahealth.."h) ")
    elseif deltahealth > 0 and vitalspam==true then
     cecho("<green>(+"..deltahealth.."h) ")
    end
    
    if deltamana < 0 and vitalspam==true then
     cecho("<SlateBlue>("..deltamana.."m) ")
    elseif deltamana > 0 and vitalspam==true then
     cecho("<DodgerBlue>(+"..deltamana.."m) ")
    end
    
    if flags~=0 then
     flagdisplay(special)
    end
    
    if matches[7]=="f" then
    focus=0
    else
    focus=1
    end
    
    if matches[8]=="u" then
    balance=0
    else
    balance=1
    end
    
    if undead==true and hbalance==true and health < siphealth then
     send("sip blood")
     hbalance=false
    elseif undead==false and hbalance==true and health < siphealth then
     send("sip health")
     hbalance=false
    end
    
    if mbalance==true and mana < sipmana then
     send("sip mana")
     mbalance=false
    end
    
    if arnica==true and abalance==true and health < eathealth then
     expandAlias("arnica")
     abalance=false
    end
    
    if balance==1 and focus==1 then
    send(table.remove(actionqueue, 1))
    end
    Match:
    Code:
    ^You could drink another health potion now\.$
    -
    ^You may consume more blood now\.$
    Script:
    Code:
    hbalance=true
    Addendum: Undead tracking is of course monitored by a login/def check thing.
    Last edited by Nakarym; 6 January 2016, 08:25 PM.

    Comment


    • #3
      Weeeellll I was going to post mine but it looks like Nakarym's except less fancy. The main difference is a have 2 variables healOn and mossOn that control if I sip or use arnica(yes I know arnica is not a moss), for things that get interrupted by inputting commands such as locks, chops, throatrips. I also have a variable to check for eternity(part of my affliction system) and it doesn't allow sipping or arnica use while eternity is in effect.

      If I had my old ZMUD stuff I would post that too, but unfortunately I lost it somewhere.
      Seig is rather Dashing and Charming no?


      Dashing Seig says, "We should run an ass slapping train on dat phat booty"
      2240/2240h 280/280m 58xp >
      Words to Live By:
      "I dont assume to understand women" -Sir Magnum Veritan 2016
      "...and RNGesus hates me cause I don't believe in him so..." -myself 2016

      Comment


      • #4
        Yeah, I should make a dupe for arnica, and do the same things you have for throatrips, and the check for eternity would be super great blah.

        Comment


        • #5
          I'll share my mediocre sipper for the html5 client, since that is where I started before switching to Mudlet. Its always useful to have this when starting a new game.

          Pattern:
          Code:
          (\d+)/(\d+)h (\d+)/(\d+)m (.*)
          Script:
          Code:
          curHealthPercent = PatternMatches[1] / PatternMatches[2]
          if (curHealthPercent < 0.86 && sipBal == true){
            send("sip health");
            sipBal = false;
          }
          Pattern:
          Code:
          Your wounds tingle and reknit themselves from within.
          Script:
          Code:
          sipBal = false;
          Pattern:
          Code:
          You could drink another health potion now.
          Script:
          Code:
          sipBal = true;
          rudimentary I know, but I didn't use the client past novicehood. this should however help those who are new to Akanbar and wish to play via the html5 client.

          Comment


          • #6
            Originally posted by Aidan View Post
            rudimentary I know, but I didn't use the client past novicehood. this should however help those who are new to Akanbar and wish to play via the html5 client.
            An excellent thought, I approve!

            Comment

            Working...
            X