Brian Koponen

Programming and Tech Tips

Must Have Hunter Macros for Vanilla World of Warcraft

I have created a new page for World of Warcraft: Classic Hunter Macros.

The Hunter is probably the easiest class to play solo in Vanilla World of Warcraft, but it is also easy to play poorly. Especially when soloing, you need quick, direct access to a lot of skills when an encounter starts to turn ugly. It is amazing the kind of situations a hunter can deal with when you have your full arsenal of tools available.

There are a lot of skills that have very situational uses and the only effective way to use them is with a lot of macros. Many of these are advanced macros that bind many skills to a single key. These take some practice to get used to, but I promise it is worth the time and effort.

To make the most of these macros, I highly recommend trying The Best Control Scheme for World of Warcraft. It allows you to use tons of keybindings very easily, which is useful when you have a lot of macros like this. If you are new to Vanilla WoW, you may want to see my guide on Leveling a Hunter in Vanilla World of Warcraft.

These macros are made for the 1.12.1 client version of World of Warcraft. I also have a page for World of Warcraft: Classic. I make use of these addons very heavily:

Also, many of these macros use modifier keys to alter their functionality. You may want to switch those modifier keys depending on your preference. Those functions are:

Table of Contents

Universal Macros

First of all, let's look at a few macros that are really useful for all classes.

A really handy macro trick is to make the first line:

/run --CastSpellByName("Spell")

This will give the macro the cool down and range check on your action bar of the spell you put in the quotes. This doesn't actually cast the spell because the double dash is used as a comment delimiter and prevents the rest of the line from being executed. However, the World of Warcraft client simply looks for the first CastSpellByName reference, even if it is in a comment, to decide how the cool down and range check will be determined.

Target Nearest Enemy

This is a very useful line to have in many macros. It simply targets the nearest enemy if you don't already have a target.

/run if GetUnitName("target")==nil then TargetNearestEnemy() end

Change Action Bar

In many classes, you will have different sets of spells that are cast together. It can be very useful to have those spells organized onto different action bars and have macros switch to those bars as is appropriate.

Using the default UI, you can switch the active action bar like this:

/run ChangeActionBarPage()

A very popular action bar replacement addon is Bongos. Using the Bongos addon you can show or hide a bar like this:

/bob show [bar number]
/bob hide [bar number]

You may find these useful depending on your keybindings and play style.

Fishing and Mounting

This is a general purpose macro that casts fishing if a fishing pole is equipped, otherwise it mounts/dismounts as long as your mount is on the twelfth spot of your action bar.

/run local i = GetInventoryItemTexture("player", GetInventorySlotInfo("MainHandSlot")) if i and string.find(i,"INV_Fishingpole") then CastSpellByName("Fishing") else UseAction(12) end

Hunter Specific Macros

Now let's get into the Hunter specific macros.

Main Attack

This is a set of three macros. One for Melee attack, one for Ranged attack and one to choose between them. These are also where I switch action bars.

The first macro targets the nearest enemy and then attacks appropriately based on the distance to the target.

/run if GetUnitName("target")==nil then TargetNearestEnemy() end
/run if CheckInteractDistance("target", 3) then RunMacro("Melee") else RunMacro("Range") end

The Melee macro can be spammed without cancelling auto attack. Since I rarely melee, I added Raptor Strike and Mongoose Bite into a one button macro.

/run ChangeActionBarPage()
/bob show 1
/run castAttack()
/run castRaptor()
/run castMong()

The Range macro can also be spammed without cancelling AutoShot. While you could add other attacks into this macro, it is better to use each shot situationally for the best mana usage.

/run ChangeActionBarPage()
/bob hide 1
/run castAutoShot()


Zorlen castSting() will choose the appropriate sting for the target. It will also not cast Serpent Sting if a mob is immune or is below 20% health to conserve mana. That is why I have the modifier cast Serpent Sting directly. If I have to kite a mob, I can force that sting.

/run --CastSpellByName("Serpent Sting")
/run if GetUnitName("target")==nil then TargetNearestEnemy() end
/run if IsShiftKeyDown() then CastSpellByName("Serpent Sting") else castSting() end

Wing Clip / Concussive Shot

This is a simple one that casts either Wing Clip or Concussive Shot depending on distance. If the target is already Wing Clipped, it won't cast Concussive Shot.

/run --CastSpellByName("Concussive Shot")
/run if CheckInteractDistance("target", 3) then castClip() else castCon() end

Pet Attack and Recall

This is an amazing one button macro for handling your pet while in combat. You need to be able to command your pet to do three things while in combat: attack your target, assist an ally or stop attacking and return to you. This macro will do all of those with one press, based on the situations below.

Pet Command Situation
Attack Target Hunter's target is an enemy.
Assist Target Hunter's target is an ally.
Recall Pet Hunter and Pet have same target or Hunter has no target.

Each time the pet is told to move, Dash and Dive are cast. When the pet attacks, Furious Howl is cast as well as Growl turned on and Cower turned off. If you are doing primarily PvP or dungeons / raids, you may want to remove zGrowlAutocastOn() so Growl does not get cast.

/script if UnitExists("target") then if UnitIsFriend("player","target") then AssistUnit("target"); zFuriousHowl(); PetAttack(); zDash(); zDive(); else if UnitExists("pettarget") and UnitIsUnit("target", "pettarget") then PetFollow(); zDash(); zDive();else zCowerAutocastOff(); zGrowlAutocastOn(); zFuriousHowl(); PetAttack(); zDash(); zDive(); end;end;else PetFollow(); zDash(); zDive(); end;

Pet Feed / Mend / Revive / Call / Dismiss

The second macro handles all the other pet commands in one macro. This requires SuperMacro's Extended Lua function to work.

Effect Situation
Call Pet Pet isn't out.
Revive Pet Pet is dead.
Mend Pet (Max Level) Pet is in combat and has a target.
Mend Pet (Most Efficient) Shift Modifier.
Feed Pet Pet is out of combat and not happy. (Special Case: Pet is in combat without a target. Often after reviving, the pet is still marked as in combat even though it isn't.)
Dismiss Pet Pet is happy and not in combat.

Feed Pet

This is SmartRestore's feature to feed the pet. Call this macro "Feed Pet" and it will be used by the function below.

/sr feed

Pet Care

Now create a second macro called PetCare that just has this one line.

/run PetCare();

Extended Lua

SuperMacro allows us to write functions in the Lua scripting language that World of Warcraft uses to create more sophisticated functions than can be created in the raw macro language. Make sure to copy this into the Extended Lua section and not into the macro section of the SuperMacro window.

function PetCare()
    if( IsShiftKeyDown()) then
    elseif (not UnitExists("pet")) then
      CastSpellByName("Call Pet");
    elseif (UnitHealth("pet")==0) then
      CastSpellByName("Revive Pet");
    elseif (Zorlen_petInCombat()) then
      if UnitExists("pettarget") then
        RunMacro("Feed Pet")
    elseif (GetPetHappiness()~=3) then
      RunMacro("Feed Pet");
      CastSpellByName("Dismiss Pet");

Threat Management

This pair of macros can be useful when soloing and trying to deal with a bad pull. The first raises the hunter's threat with Distracting Shot and lowers the pet's threat by turning off Growl and turning on Cower.

/run --CastSpellByName("Distracting Shot")
/run castDistract();
/run zCowerAutocastOn();
/run zGrowlAutocastOff();

The second is the reverse, lowering the hunter's threat with Disengage and raising the pet's threat by turning on Growl and attacking the hunter's target.

/run --CastSpellByName("Disengage")
/run zCowerAutocastOff();
/run zGrowlAutocastOn();
/run PetAttack();
/run castDisengage();


For traps, these cast Feign Death if the hunter is in combat, then cast the trap on the second try. These are designed to be spammed, so keep hitting the macro until the trap is laid.

/run --CastSpellByName("Immolation Trap")
/run if (canTrap()) then if IsShiftKeyDown() then castExplosiveTrap() else castImmolationTrap() end else castFeign() end

For Frost and Freezing Trap, in addition to casting Feign Death, the pet is told to stop attacking so it doesn't break the trap. Technically, you don't need to stop the pet when casting Frost Trap, but I don't use it frequently enough for it to be a bother.

/run --CastSpellByName("Freezing Trap")
/run if UnitAffectingCombat("player") then castFeign(); PetFollow(); PetPassiveMode(); ClearTarget(); TargetLastEnemy(); else if IsShiftKeyDown() then castFrostTrap(); else CastSpellByName("Freezing Trap");end end


This macro casts Aspect of the Monkey or Aspect of the Hawk based on the distance to the target.

/run if CheckInteractDistance("target", 3) then castMonkey() else castHawk() end

Feign Death

This casts Feign Death only if the hunter is in combat.

/run --CastSpellByName("Feign Death")
/run if UnitAffectingCombat("player") then castFeign() end

General Zorlen

Zorlen will save enough mana to cast Feign Death if you use its functions, so I make a macro for basically every shot.

/run --CastSpellByName("Arcane Shot")
/run if GetUnitName("target")==nil then TargetNearestEnemy() end
/run castArcane()

This will only cast Hunter's Mark if the target is not already marked.

/run --CastSpellByName("Hunter's Mark")
/run if(not isMarked()) then castMark();end


This uses the SmartRestore addon to use a potion depending on need. Hold shift to use a bandage.

/run if IsShiftKeyDown() then SR_Bandage(); else SR_SmartUse(); end


This uses the SmartEngineer addon to throw a bomb or grenade. Especially useful when leveling and you have several types in your inventory.

/se boom


I have a whole page dedicated to some of the most useful Vanilla World of Warcraft Addons that are universal to all classes. But these addons are specific to the Hunter class. Most of these just get rid of annoyances that build up over time.


When I started creating all these macros, it really transformed the game for me. I found it much easier to solo content and survive situations that were otherwise too much for me. I hope these have the same effect for you as well.

You may also be interested in these World of Warcraft related pages:

Question or Comment?