[Release] Hunter Lua Macro menu

User Tag List

Page 1 of 2 12 LastLast
Results 1 to 15 of 21
  1. #1
    demisehi's Avatar Member
    Reputation
    50
    Join Date
    Jun 2009
    Posts
    147
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    [Release] Hunter Lua Macro

    Hell with it. Since I am really not playing my hunter anymore, might as well release this for the short time remaining we have PLUA unlockers available. I would like to thank CaptJesus, Ssateneth, Chaotic. If I left anyone out, I apologize.

    These were current as of Pre-Firelands, and I honestly have not made any changes to them post firelands release except the Careful Aim change from 80% health to 90% health. Don't say I never contributed.

    How to use:

    - Download Hack or Devpad
    - Make a hack or devpad page and stick the marksman content into it.
    - Make a macro specifically to call the hack or devpad marksman macro.
    - Make a normal macro called aoeflag and stick the aoeflag contents into it
    - Make a normal macro called misdirect and stick the misdirect contents into it
    - Copy the above 3 macros onto your button bar.
    - Use the misdirect and aoeflag switches accordingly.
    - Create a "Misdirection" macro with a common macro found on the forums. Usually something like Misdirect to focus, if no foucs, then tank, etc etc. All hunters have one.
    - Put Aimed Shot on your bar, and find out where it is mapped to. Change the /click BT4Button27 to whatever correlates to yours to case Aimed Shot! when appropriate.

    The switches (misdirect and aoeflag) change variables within the marksman macro and will perform different priorities. Press them once to achieve one flag, again to revert back. Rinse and repeat.

    If you have any questions, let me know.

    The Macros:

    aoeflag
    Code:
    #showtooltip
    /run if aoeflag==nil then aoeflag=1 SetMacroSpell("aoeflag","Multi-Shot") elseif aoeflag==1 then aoeflag=nil SetMacroSpell("aoeflag","Steady Shot") end

    misdirect
    Code:
    #showtooltip
    /run if md==nil then md=1 SetMacroSpell("misdirect","Misdirection") elseif md==1 then md=nil SetMacroSpell("misdirect","Scare Beast") end
    marksman
    Code:
    ------INITIALIZE------
    cast = CastSpellByName
    
    
    ------SPEC------
    pt = GetPrimaryTalentTree();
    
    
    ------MOVEMENT------
    if GetUnitSpeed("player")>0 and not UnitAura("player","Aspect of the Fox") and GetSpellCooldown("Aspect of the Fox")==0 then
      cast("Aspect of the Fox")
    elseif GetUnitSpeed("player")==0 and not UnitAura("player","Aspect of the Hawk") and GetSpellCooldown("Aspect of the Hawk")==0 then
      cast("Aspect of the Hawk")
    end
    
    
    ------THREAT------
    t={UnitDetailedThreatSituation("player","target")}
    if GetNumPartyMembers()>0 and (t[1]==1 or (t[5] ~=nil and t[5]>25000 and t[3]>90)) then
      if GetSpellCooldown("Feign Death")==0 then
        cast("Feign Death")
      end
    end
    
    
    ------TRANQUILIZING SHOT------
    if GetSpellCooldown("Tranquilizing Shot")==0 and UnitPower("player")>19 and IsSpellInRange("Tranquilizing Shot","target")==1 and (UnitBuff("target","Enrage") or UnitBuff("target","Remedy") or UnitBuff("target","Rage") or UnitBuff("target","Power Conversion") or UnitBuff("target","Venomous Rage") or UnitBuff("target","Rapid Fire")) then
      cast("Tranquilizing Shot")
    end
    
    
    ------HUNTERS MARK------
    if (UnitLevel("target")==-1 or (UnitLevel("target")==UnitLevel("player")+2 and select(2,GetInstanceInfo())=="party")) then
      if not (UnitDebuff("target","Hunter's Mark") or UnitDebuff("target","Marked for Death")) and UnitHealth("target")/UnitHealthMax("target")>=.95 then
        cast("Hunter's Mark")
      end
    end
    
    ------MISDIRECTION------
    if md and not UnitCastingInfo("player") and UnitAffectingCombat("player")==1 then
      if GetSpellCooldown("Misdirection")==0 and not UnitBuff("player","Misdirection") then
        RunMacro("Misdirection")
      end
    end
    
    
    
    ------SERPENT STING------
    if not UnitDebuff("target","Serpent Sting","","player") then
      ssremain=0
    elseif UnitDebuff("target","Serpent Sting","","player") then 
      ssremain=select(7,UnitDebuff("target","Serpent Sting","","player"))-GetTime()
    end
    
    
    ------AOE------
    if aoeflag and pt==2 then
      if not UnitCastingInfo("player") and select(2,IsUsableSpell("Multi-Shot"))==nil and GetSpellCooldown("Multi-Shot")==0 then
        cast("Multi-Shot")
      elseif not UnitCastingInfo("player") and UnitBuff("player","Fire!") and GetSpellCooldown("Steady Shot")==0 then
        RunMacroText("/click BT4Button27")
      elseif not UnitCastingInfo("player") and UnitPower("player")<=39 and GetSpellCooldown("Steady Shot")==0 then
        cast("Steady Shot")
      end
    elseif aoeflag and pt==3 then
      if not UnitCastingInfo("player") and select(2,IsUsableSpell("Multi-Shot"))==nil and GetSpellCooldown("Multi-Shot")==0 then
        cast("Multi-Shot")
      elseif not UnitCastingInfo("player") and GetSpellCooldown("Cobra Shot")==0 then
        cast("Cobra Shot")
      end
    end
    
    
    ------RAPID FIRE AND READINESS------
    if (UnitLevel("target")==-1 or (UnitLevel("target")==UnitLevel("player")+2 and select(2,GetInstanceInfo())=="party")) then
      if not UnitCastingInfo("player") then
        if GetSpellCooldown("Rapid Fire")==0 and GetSpellCooldown("Serpent Sting")==0 and not UnitBuff("player","Bloodlust") and UnitHealth("target")/UnitHealthMax("target")>=0.05 then
          cast("Rapid Fire")
        elseif pt==2 and GetSpellCooldown("Readiness")==0 and GetSpellCooldown("Serpent Sting")==0 and (GetSpellCooldown("Rapid Fire")+select(2,GetSpellCooldown("Rapid Fire"))-GetTime()>30) and not UnitBuff("player","Rapid Fire") and UnitHealth("target")/UnitHealthMax("target")>=0.05 then
          cast("Readiness")
        end
      end
    end
    
    
    ------PET HEAL------
    if UnitExists("pet") then
      if UnitHealth("pet")/UnitHealthMax("pet")<0.60 and not UnitBuff("pet","Mend Pet") then
        cast("Mend Pet")
      end
    end
    
    
    ------PHASES AND MAIN------
    if UnitHealth("target")/UnitHealthMax("target")>=0.90 then
      phase=1
    elseif UnitHealth("target")/UnitHealthMax("target")<0.90 and UnitHealth("target")/UnitHealthMax("target")>=0.20 then
      phase=2
    elseif UnitHealth("target")/UnitHealthMax("target")<0.20 then
      phase=3
    end
    if UnitAura("player","Aspect of the Fox") and not UnitCastingInfo("player") and GetSpellCooldown("Steady Shot")==0 then
      cast("Steady Shot")
    end
    
    if not aoeflag and pt==2 then
      if phase==1 and not UnitCastingInfo("player") then
        if UnitBuff("player","Fire!") and GetSpellCooldown("Aimed Shot")==0 then
          RunMacroText("/click BT4Button27")     
        elseif GetSpellCooldown("Aimed Shot")==0 and UnitPower("player")>=75 or (select(2,IsUsableSpell("Aimed Shot"))==nil and (UnitBuff("player","Bloodlust") or UnitBuff("player","Rapid Fire"))) then
          cast("Aimed Shot")
        elseif UnitPower("player")<79 and not UnitCastingInfo("player") and GetSpellCooldown("Steady Shot")==0 then
          cast("Steady Shot")
        end
      elseif phase==2 and not UnitCastingInfo("player") then
        if ssremain==0 and GetSpellCooldown("Serpent Sting")==0 and select(2,IsUsableSpell("Serpent Sting"))==nil then  
          cast("Serpent Sting")
        elseif select(2,IsUsableSpell("Chimera Shot"))==nil and GetSpellCooldown("Chimera Shot")==0 and GetSpellCooldown("Serpent Sting")==0 then
          cast("Chimera Shot")
        elseif UnitBuff("player","Fire!") and GetSpellCooldown("Aimed Shot")==0 then
          RunMacroText("/click BT4Button27")
        elseif GetSpellCooldown("Aimed Shot")==0 and select(2,IsUsableSpell("Aimed Shot"))==nil and (GetSpellCooldown("Chimera Shot")>5 or UnitBuff("player","Bloodlust") or UnitBuff("player","Rapid Fire")) then
          cast("Aimed Shot")
        elseif not UnitBuff("player","Improved Steady Shot") and GetSpellCooldown("Steady Shot")==0 then
          cast("Steady Shot")
        elseif GetSpellCooldown("Steady Shot")==0 then
          cast("Steady Shot")
        end
      elseif phase==3 and not UnitCastingInfo("player") then
        if ssremain==0 and GetSpellCooldown("Serpent Sting")==0 and select(2,IsUsableSpell("Serpent Sting"))==nil then
          cast("Serpent Sting")
        elseif GetSpellCooldown("Kill Shot")==0 and GetSpellCooldown("Steady Shot")==0 then
          cast("Kill Shot")
        elseif select(2,IsUsableSpell("Chimera Shot"))==nil and GetSpellCooldown("Chimera Shot")==0 and GetSpellCooldown("Serpent Sting")==0 then
          cast("Chimera Shot")
        elseif UnitBuff("player","Fire!") and GetSpellCooldown("Aimed Shot")==0 then
          RunMacroText("/click BT4Button27")
        elseif GetSpellCooldown("Aimed Shot")==0 and select(2,IsUsableSpell("Aimed Shot"))==nil and (GetSpellCooldown("Chimera Shot")>5 or UnitBuff("player","Bloodlust") or UnitBuff("player","Rapid Fire")) then
          cast("Aimed Shot")
        elseif not UnitBuff("player","Improved Steady Shot") and GetSpellCooldown("Steady Shot")==0 then
          cast("Steady Shot")
        elseif GetSpellCooldown("Steady Shot")==0 then
          cast("Steady Shot")
        end
      end
    elseif not aoeflag and pt==3 then
      if (phase==1 or phase==2) and not UnitCastingInfo("player") then
        if ssremain==0 and GetSpellCooldown("Serpent Sting")==0 and select(2,IsUsableSpell("Serpent Sting"))==nil then
          cast("Serpent Sting")
        elseif UnitBuff("player","Lock and Load") and select(2,IsUsableSpell("Explosive Shot"))==nil and GetSpellCooldown("Explosive Shot")==0 and GetSpellCooldown("Serpent Sting")==0 then
          cast("Explosive Shot")
        elseif select(2,IsUsableSpell("Explosive Shot"))==nil and GetSpellCooldown("Explosive Shot")==0 and GetSpellCooldown("Serpent Sting")==0 then
          cast("Explosive Shot")
        elseif select(2,IsUsableSpell("Black Arrow"))==nil and GetSpellCooldown("Black Arrow")==0 and GetSpellCooldown("Serpent Sting")==0 then
          cast("Black Arrow")
        elseif UnitPower("player")>60 and not UnitBuff("player","Lock and Load") and select(2,IsUsableSpell("Arcane Shot"))==nil and GetSpellCooldown("Arcane Shot")==0 and GetSpellCooldown("Serpent Sting")==0  then
          cast("Arcane Shot")
        elseif select(2,IsUsableSpell("Cobra Shot"))==nil and GetSpellCooldown("Cobra Shot")==0 and GetSpellCooldown("Serpent Sting")==0 then
          cast("Cobra Shot")
        end
      elseif phase==3 and not UnitCastingInfo("player") then
        if ssremain==0 and GetSpellCooldown("Serpent Sting")==0 and select(2,IsUsableSpell("Serpent Sting"))==nil then
          cast("Serpent Sting")
        elseif UnitBuff("player","Lock and Load") and select(2,IsUsableSpell("Explosive Shot"))==nil and GetSpellCooldown("Explosive Shot")==0 and GetSpellCooldown("Serpent Sting")==0 then
          cast("Explosive Shot")
        elseif select(2,IsUsableSpell("Explosive Shot"))==nil and GetSpellCooldown("Explosive Shot")==0 and GetSpellCooldown("Serpent Sting")==0 then
          cast("Explosive Shot")
        elseif select(2,IsUsableSpell("Black Arrow"))==nil and GetSpellCooldown("Black Arrow")==0 and GetSpellCooldown("Serpent Sting")==0 then
          cast("Black Arrow")
        elseif GetSpellCooldown("Kill Shot")==0 and GetSpellCooldown("Steady Shot")==0 then
          cast("Kill Shot")
        elseif UnitPower("player")>60 and not UnitBuff("player","Lock and Load") and select(2,IsUsableSpell("Arcane Shot"))==nil and GetSpellCooldown("Arcane Shot")==0 and GetSpellCooldown("Serpent Sting")==0 then
          cast("Arcane Shot")
        elseif select(2,IsUsableSpell("Cobra Shot"))==nil and GetSpellCooldown("Cobra Shot")==0 and GetSpellCooldown("Serpent Sting")==0 then
          cast("Cobra Shot")
        end
      end
    end
    Last edited by demisehi; 07-21-2011 at 11:08 AM.

    [Release] Hunter Lua Macro
  2. #2
    Parrky's Avatar Contributor
    Reputation
    146
    Join Date
    Aug 2010
    Posts
    270
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Better than mine at least

  3. #3
    demisehi's Avatar Member
    Reputation
    50
    Join Date
    Jun 2009
    Posts
    147
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    It started out as Marksman, but if you switch to Survival, it will run that priority as well. Traps you have to manually do yourself, but thats not a big deal.

  4. #4
    SprayPlaster's Avatar Sergeant Major
    Reputation
    13
    Join Date
    Feb 2010
    Posts
    164
    Thanks G/R
    0/0
    Trade Feedback
    3 (100%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    These are some nicely thought of macros you're posting here, wish I can rep more. Hopefully the end of the plua unlocker availability aint anytime soon...

  5. #5
    CrazyCactuaR's Avatar Contributor
    Reputation
    84
    Join Date
    Sep 2008
    Posts
    201
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by demisehi View Post
    It started out as Marksman, but if you switch to Survival, it will run that priority as well. Traps you have to manually do yourself, but thats not a big deal.
    instead of clicking a button for aimed shot, why not just cast Aimed Shot!, which will fire the free proc?

  6. #6
    demisehi's Avatar Member
    Reputation
    50
    Join Date
    Jun 2009
    Posts
    147
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Initially when I wrote the macro, you could never use a "/cast Aimed Shot!". If you check logs, it would never cast it. So this was the solution.

  7. #7
    CrazyCactuaR's Avatar Contributor
    Reputation
    84
    Join Date
    Sep 2008
    Posts
    201
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by demisehi View Post
    Initially when I wrote the macro, you could never use a "/cast Aimed Shot!". If you check logs, it would never cast it. So this was the solution.
    Nice work around indeed then

  8. #8
    SprayPlaster's Avatar Sergeant Major
    Reputation
    13
    Join Date
    Feb 2010
    Posts
    164
    Thanks G/R
    0/0
    Trade Feedback
    3 (100%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Just tested it out on my survival hunter, works nicely when standing still but when you start to move it uses the MM rotation instead. Oh, and for Lock and Load seems like the macro makes you use 3 explosive shots back to back, not sure why though, because in the macro it says to use arcane shot in between two explosive shots.
    Last edited by SprayPlaster; 07-19-2011 at 01:59 AM.

  9. #9
    demisehi's Avatar Member
    Reputation
    50
    Join Date
    Jun 2009
    Posts
    147
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The survival part was really never tested. I can look at it later. It is probably something simple.

  10. #10
    tsien's Avatar Private
    Reputation
    1
    Join Date
    Jul 2011
    Posts
    5
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi thnks for your job ^^

    it's work perfectly but then i click on aoeflag, my hunt don't cast multi shot then i spam the macro to call the hack,

    Thanks ^^

  11. #11
    demisehi's Avatar Member
    Reputation
    50
    Join Date
    Jun 2009
    Posts
    147
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by tsien View Post
    Hi thnks for your job ^^

    it's work perfectly but then i click on aoeflag, my hunt don't cast multi shot then i spam the macro to call the hack,

    Thanks ^^
    Fixed a typo in the original for the aoeflag, should work now for you.

    ---------- Post added at 09:13 AM ---------- Previous post was at 09:10 AM ----------

    Originally Posted by SprayPlaster View Post
    Just tested it out on my survival hunter, works nicely when standing still but when you start to move it uses the MM rotation instead. Oh, and for Lock and Load seems like the macro makes you use 3 explosive shots back to back, not sure why though, because in the macro it says to use arcane shot in between two explosive shots.
    I tested it last night and didn't have an issue with it at all, maybe a latency thing in determining buff lengths?

  12. #12
    SprayPlaster's Avatar Sergeant Major
    Reputation
    13
    Join Date
    Feb 2010
    Posts
    164
    Thanks G/R
    0/0
    Trade Feedback
    3 (100%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by demisehi View Post
    Fixed a typo in the original for the aoeflag, should work now for you.

    ---------- Post added at 09:13 AM ---------- Previous post was at 09:10 AM ----------



    I tested it last night and didn't have an issue with it at all, maybe a latency thing in determining buff lengths?
    Hmm, I'm not so sure what the problem was, LnL is executed perfectly now. The movement rotation not so much, it still casts steady shot while in survival spec if I move. It's no biggie though, I just replace all the steady shots in the macro into cobra shots (yes, I'm too computer illiterate to actually find out what's wrong so I just replace everything >.>). Thanks again for the great macro.

  13. #13
    ven's Avatar Member
    Reputation
    2
    Join Date
    Nov 2006
    Posts
    30
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    - Make a macro specifically to call the hack or devpad marksman macro.

    How?

  14. #14
    k4hn's Avatar Sergeant
    Reputation
    15
    Join Date
    Sep 2010
    Posts
    43
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    there's only one little problem with this 90% awesome macro.
    whenever your pet dies and aoeflag is off (single target only), spamming the marksman macro will make the hunter bug and try to heal the pet. the hunter just keeps doing this.

    so if you're using this in party/raid and your pet dies, you're screwed.

  15. #15
    demisehi's Avatar Member
    Reputation
    50
    Join Date
    Jun 2009
    Posts
    147
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Looking at it, it shouldn't bug at all.

    Code:
    ------PET HEAL------
    if UnitExists("pet") then
      if UnitHealth("pet")/UnitHealthMax("pet")<0.60 and not UnitBuff("pet","Mend Pet") then
        cast("Mend Pet")
      end
    end
    It shouldn't try and heal pet unless you have one and its health is low.


    I haven't looked at or done anything with my hunter since before I posted this, but if I do get back to him, I will rewrite some of it to be a little more optimized.

Page 1 of 2 12 LastLast

Similar Threads

  1. [Release] Feral DPS Druid Lua Macro
    By demisehi in forum WoW UI, Macros and Talent Specs
    Replies: 9
    Last Post: 06-03-2013, 11:56 PM
  2. [Release] Mutilate Rogue Lua Macro
    By demisehi in forum WoW UI, Macros and Talent Specs
    Replies: 1
    Last Post: 10-20-2011, 01:13 PM
  3. [Release] Portal Lua Event
    By Spartansp in forum World of Warcraft Emulator Servers
    Replies: 28
    Last Post: 02-04-2008, 09:46 AM
  4. Hunter MD macro
    By kartok in forum WoW UI, Macros and Talent Specs
    Replies: 4
    Last Post: 01-24-2008, 02:21 PM
  5. [RELEASE??] Hunter starting with stealth & pickpocket
    By pepsi1x1 in forum World of Warcraft Emulator Servers
    Replies: 2
    Last Post: 12-04-2007, 11:06 PM
All times are GMT -5. The time now is 04:53 AM. Powered by vBulletin® Version 4.2.3
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Google Authenticator verification provided by Two-Factor Authentication (Free) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search