Skip to content

Instantly share code, notes, and snippets.

@brandonjank
Last active August 29, 2015 14:04
Show Gist options
  • Save brandonjank/85b08a0bf5ca11eeb61a to your computer and use it in GitHub Desktop.
Save brandonjank/85b08a0bf5ca11eeb61a to your computer and use it in GitHub Desktop.
-- Backburn's Survival Hunter Rotation
-- Updated on July 17th, 2014.
-- PLAYER CONTROLLED: Rabid MUST be on Auto-Cast for Stampede pets to use them :)
-- SUGGESTED TALENTS:
-- CONTROLS: Pause - Left Control, Explosive/Ice/Snake Traps - Left Alt, Freezing Trap - Right Alt, Scatter Shot - Right Control
local class = 'Hunter'
local spec = 'Survival'
-- TOGGLES
local toggles = {
{'callpet', 'Interface\\Icons\\ability_hunter_beastcall', 'Call Pet 1', 'Toggle to keep the pet in your first pet slot out.'},
{'misdirect', 'Interface\\Icons\\ability_hunter_misdirection', 'Auto Misdirect', 'Toggle to automatically misdirect to your Focus>Tank>Pet when high on threat.'},
{'consume', 'Interface\\Icons\\inv_alchemy_endlessflask_06', 'Use Consumables', 'Toggle the usage of Flasks/Food/Potions etc..'},
{'autotarget', 'Interface\\Icons\\ability_hunter_snipershot', 'Auto Target', 'Automatically target the nearest enemy when target dies or does not exist.'},
{'aspect', 'Interface\\Icons\\ability_mount_jungletiger', 'Auto Aspect', 'Automatically switch aspect when moving and not in combat.'},
{'mouseovers', 'Interface\\Icons\\ability_hunter_quickshot', 'Use Mouseovers', 'Toggle automatic usage of stings/scatter/etc on eligible mouseover targets.'},
{'pvpmode', 'Interface\\Icons\\achievement_pvp_o_h', 'Enable PvP', 'Toggle the usage of PvP abilities.'},
{'camomode', 'Interface\\Icons\\ability_hunter_displacement', 'Use Camouflage', 'Toggle the usage Camouflage when out of combat.'},
{'cleavemode', 'Interface\\Icons\\ability_upgrademoonglaive', 'Cleave Mode', 'Toggle the automatic usage of AoE abilities for 2 to 3 enemies.'}
}
-- COMBAT
local combat = {
-- Rotation Utilities
-- TODO: Explosive Trap timer cooldown OSD
-- cant place traps without target?
-- TODO: DPS Test Function
pause('Pause Rotation', function()
return modifier('lcontrol') -- Pause Key
or '@bbLib.bossMods' -- Boss Pause
or unit('player').buff(5384)' -- Feign Death
end)
--bbLib.BGFlag
macro('/targetenemy [noexists]', function()
return toggle('autotarget') and not unit('target').exists()
end),
macro('/targetenemy [dead]', function()
return toggle('autotarget') and unit('target').exists() and unit('target').dead()
end),
-- Interrupts
spell(147362, unit('target'), function() -- Counter Shot
return unit('target').range() < 40 and unit('target').randinterrupt()
end),
-- Pet
spell(883, unit('player'), function() -- Call Pet 1
return toggle('callpet') and not unit('pet').exists()
end),
spell(55709, unit('pet'), function() -- Heart of the Phoenix
return toggle('callpet') and unit('pet').dead()
end),
spell(136, unit('pet'), function() -- Mend Pet
return unit('pet').exists() and unit('pet').health() < 50 and not unit('pet').buff('136') and unit('pet').range() < 40
end),
-- PvP Abilities
spell(53271, unit('player'), function() -- Master's Call
return player.state.disorient or player.state.stun or player.state.root or player.state.snare
end),
spell(19503, unit('target'), function() -- Scatter Shot on Target
return toggle('pvpmode') and unit('target').exists() and unit('target').enemy() and unit('target').alive() and not unit('target').status('disorient')
and not unit('target').status('sleep') and not unit('target').status('incapacitate') and not unit('target').status('fear') and not unit('target').status('misc') and not unit('target').status('root')
and not unit('target').status('stun') and not unit('target').status('snare') and not unit('target').status('immune', 'all') and not unit('target').status('immune', 'disorient')
end),
spell(19503, unit('mouseover'), function() -- Scatter Shot on Mouseover
return ( (toggle('mouseovers') and toggle('pvpmode')) or modifier('rcontrol') ) and unit('mouseover').exists() and unit('mouseover').enemy() and unit('mouseover').alive() and not unit('mouseover').status('disorient')
and not unit('mouseover').status('sleep') and not unit('mouseover').status('incapacitate') and not unit('mouseover').status('fear') and not unit('mouseover').status('misc') and not unit('mouseover').status('root')
and not unit('mouseover').status('stun') and not unit('mouseover').status('snare') and not unit('mouseover').status('immune', 'all') and not unit('mouseover').status('immune', 'disorient')
end),
}
local nocombat = {
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment