Code:
<?xml version="1.0" encoding="utf-8"?>
<DRUID>
<Ability>
<Name>Faerie Fire (Feral)</Name>
<Default>false</Default>
<SpellID>16857</SpellID>
<Actions></Actions>
<Lua>local FF, _, _, _, _, _, timer = UnitDebuffID(&quot;target&quot;, 91565)
local FFstart, FFduration, FFenabled = GetSpellCooldown(16857)
local FFcooldown = (FFstart + FFduration - GetTime())
if FF == nil then
if FFcooldown &gt; 0 then
return false
else
return true
end
end</Lua>
<RecastDelay>0</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>cat form</Name>
<Default>false</Default>
<SpellID>768</SpellID>
<Actions></Actions>
<Lua>local slowed = UnitDebuff(&quot;player&quot;, &quot;120&quot;)
local slowed = UnitDebuff(&quot;player&quot;, &quot;7302&quot;)
local slowed = UnitDebuff(&quot;player&quot;, &quot;5116&quot;)
local slowed = UnitDebuff(&quot;player&quot;, &quot;8056&quot;)
local slowed = UnitDebuff(&quot;player&quot;, &quot;45524&quot;)
if slowed ~= nil then
CastSpellByName(&quot;Cat Form&quot;, &quot;768&quot;)
end</Lua>
<RecastDelay>0</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>barkskin</Name>
<Default>false</Default>
<SpellID>22812</SpellID>
<Actions></Actions>
<Lua>local unithealth = 100 * UnitHealth(&quot;target&quot;) / UnitHealthMax(&quot;target&quot;)
if enraged == nil and unithealth &lt;= 60 then
return true
end</Lua>
<RecastDelay>0</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>s</Name>
<Default>false</Default>
<SpellID>0</SpellID>
<Actions></Actions>
<Lua>local mytarget = &quot;player&quot;
local lowest = 100 * UnitHealth(mytarget) / UnitHealthMax(mytarget)
local group = &quot;party&quot;
local members = GetNumPartyMembers()
lowhpmembers = 0
if GetNumRaidMembers() &gt; 0 then
group = &quot;raid&quot;
members = GetNumRaidMembers()
end
for i = 1, members, 1 do
local member = group..tostring(i)
local memberhp = 100 * UnitHealth(member) / UnitHealthMax(member)
if UnitGroupRolesAssigned(member) == &quot;TANK&quot; then memberhp = memberhp - 5 end
if UnitThreatSituation(member) == 3 then memberhp = memberhp - 5 end
if memberhp &lt; 95 and UnitInRange(member) then lowhpmembers = lowhpmembers +1 end
if memberhp &gt; 1 and memberhp &lt; lowest and UnitInRange(member) then
mytarget = member
lowest = memberhp
end
end
TargetUnit(mytarget)</Lua>
<RecastDelay>0</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Resto: Autotarget LowHP</Name>
<Default>false</Default>
<SpellID>0</SpellID>
<Actions></Actions>
<Lua>local mytarget = &quot;player&quot;
local lowest = 100 * UnitHealth(mytarget) / UnitHealthMax(mytarget)
local group = &quot;party&quot;
local members = GetNumPartyMembers()
lowhpmembers = 0
if GetNumRaidMembers() &gt; 0 then
group = &quot;raid&quot;
members = GetNumRaidMembers()
end
for i = 1, members, 1 do
local member = group..tostring(i)
local memberhp = 100 * UnitHealth(member) / UnitHealthMax(member)
if UnitGroupRolesAssigned(member) == &quot;TANK&quot; then memberhp = memberhp - 5 end
if UnitThreatSituation(member) == 3 then memberhp = memberhp - 5 end
if memberhp &lt; 95 and UnitInRange(member) then lowhpmembers = lowhpmembers +1 end
if memberhp &gt; 1 and memberhp &lt; lowest and UnitInRange(member) then
mytarget = member
lowest = memberhp
end
end
TargetUnit(mytarget)</Lua>
<RecastDelay>0</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Resto: Nourish</Name>
<Default>false</Default>
<SpellID>50464</SpellID>
<Actions></Actions>
<Lua>local friend = UnitIsFriend(&quot;player&quot;,&quot;target&quot;)
local mytarget = 100 * UnitHealth(&quot;target&quot;) / UnitHealthMax(&quot;target&quot;)
if friend ~= nil and PQR_IsMoving(1) == false and mytarget &lt; 90 then
return true
end</Lua>
<RecastDelay>0</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Resto: Rejuvenation</Name>
<Default>false</Default>
<SpellID>774</SpellID>
<Actions></Actions>
<Lua>local friend = UnitIsFriend(&quot;player&quot;,&quot;target&quot;)
local mytarget = 100 * UnitHealth(&quot;target&quot;) / UnitHealthMax(&quot;target&quot;)
local rejuvenation = UnitBuffID(&quot;target&quot;, 774)
if friend ~= nil and mytarget &lt; 88 and rejuvenation == nil and IsMounted() == nil then
return true
end</Lua>
<RecastDelay>0</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Resto: Wild Growth</Name>
<Default>false</Default>
<SpellID>48438</SpellID>
<Actions></Actions>
<Lua>local friend = UnitIsFriend(&quot;player&quot;,&quot;target&quot;)
local mytarget = 100 * UnitHealth(&quot;target&quot;) / UnitHealthMax(&quot;target&quot;)
if friend ~= nil and GetSpellCooldown(48438) == 0 and mytarget &lt; 67 then
return true
end</Lua>
<RecastDelay>0</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Resto: Swiftmend</Name>
<Default>false</Default>
<SpellID>18562</SpellID>
<Actions></Actions>
<Lua>local friend = UnitIsFriend(&quot;player&quot;,&quot;target&quot;)
local mytarget = 100 * UnitHealth(&quot;target&quot;) / UnitHealthMax(&quot;target&quot;)
local SM = UnitBuffID(&quot;target&quot;,774)
if friend ~= nil and SM ~= nil and mytarget &lt;72 and GetSpellCooldown(18562) == 0 then
return true
end</Lua>
<RecastDelay>0</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Resto: Regrowth</Name>
<Default>false</Default>
<SpellID>8936</SpellID>
<Actions></Actions>
<Lua>local friend = UnitIsFriend(&quot;player&quot;,&quot;target&quot;)
local mytarget = 100 * UnitHealth(&quot;target&quot;) / UnitHealthMax(&quot;target&quot;)
local manapercent = 100 * UnitPower(&quot;player&quot;) / UnitPowerMax(&quot;player&quot;)
local Clearcasting = UnitBuffID(&quot;player&quot;,16870, &quot;player&quot;)
if friend ~= nil and Clearcasting ~= nil and mytarget &lt; 75 and manapercent &gt; 15 and IsMounted() == nil then
return true
end
if friend ~= nil and PQR_IsMoving(1) == false and mytarget &lt; 40 and manapercent &gt; 15 and IsMounted() == nil then
return true
end</Lua>
<RecastDelay>500</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Resto: Innervate</Name>
<Default>false</Default>
<SpellID>29166</SpellID>
<Actions></Actions>
<Lua>local manapercent = 100 * UnitPower(&quot;player&quot;) / UnitPowerMax(&quot;player&quot;)
if manapercent &lt; 65 then
return true
end</Lua>
<RecastDelay>0</RecastDelay>
<Target>Player</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Resto: Lifebloom</Name>
<Default>false</Default>
<SpellID>33763</SpellID>
<Actions></Actions>
<Lua>local friend = UnitIsFriend(&quot;player&quot;,&quot;focus&quot;)
local mytarget = 100 * UnitHealth(&quot;focus&quot;) / UnitHealthMax(&quot;focus&quot;)
local _,_,_,LB,_,_,LBt = UnitBuffID(&quot;focus&quot;, 33763)
local treeoflife = UnitBuffID(&quot;player&quot;,33891)
if LB == nil then
return true
end
if LB ~= nil and LB &lt; 3 then
return true
end
if friend ~= nil and LB ~= nil and LBt - GetTime() &lt; 2 then
return true
end</Lua>
<RecastDelay>0</RecastDelay>
<Target>Focus</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Resto: Healing Touch</Name>
<Default>false</Default>
<SpellID>5185</SpellID>
<Actions></Actions>
<Lua>local friend = UnitIsFriend(&quot;player&quot;,&quot;target&quot;)
local mytarget = 100 * UnitHealth(&quot;target&quot;) / UnitHealthMax(&quot;target&quot;)
if friend ~= nil and PQR_IsMoving(1) == false and mytarget &lt; 55 then
return true
end</Lua>
<RecastDelay>0</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Resto: Tranquility</Name>
<Default>false</Default>
<SpellID>740</SpellID>
<Actions></Actions>
<Lua>local SwG = UnitBuffID(&quot;player&quot;, 17116)
if SwG ~= nil and GetSpellCooldown(740) == 0 and IsShiftKeyDown() then
return true
end
if PQR_IsMoving(1) == false and GetSpellCooldown(740) == 0 and IsShiftKeyDown() and IsMounted() == nil then
return true
end</Lua>
<RecastDelay>0</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Ravage</Name>
<Default>false</Default>
<SpellID>6785</SpellID>
<Actions></Actions>
<Lua>local stampede, _, _, _, _, _, stamptimer = UnitBuffID(&quot;player&quot;, 78893, &quot;PLAYER&quot;)
if stampede ~= nil then
if stamptimer - GetTime() &lt;= 1 then
return true
end
else
return true
end</Lua>
<RecastDelay>0</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Don&apos;t Dismount</Name>
<Default>false</Default>
<SpellID>0</SpellID>
<Actions></Actions>
<Lua>if IsMounted() then
return true
end</Lua>
<RecastDelay>0</RecastDelay>
<Target>Player</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Cyclone</Name>
<Default>false</Default>
<SpellID>33786</SpellID>
<Actions></Actions>
<Lua>if UnitExists(&quot;mouseover&quot;) and UnitIsUnit(&quot;mouseover&quot;,&quot;target&quot;) == nil and IsLeftControlKeyDown() then
CastSpellByID(33786,&quot;mouseover&quot;)
end</Lua>
<RecastDelay>50</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Entangling Roots</Name>
<Default>false</Default>
<SpellID>339</SpellID>
<Actions></Actions>
<Lua>if UnitExists(&quot;mouseover&quot;) and UnitIsUnit(&quot;mouseover&quot;,&quot;target&quot;) == nil and IsShiftKeyDown() then
CastSpellByID(339,&quot;mouseover&quot;)
end</Lua>
<RecastDelay>50</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Resto: Faerie Fire</Name>
<Default>false</Default>
<SpellID>770</SpellID>
<Actions></Actions>
<Lua>if UnitExists(&quot;mouseover&quot;) and UnitIsUnit(&quot;mouseover&quot;,&quot;target&quot;) == nil and IsAltKeyDown() then
CastSpellByID(770,&quot;mouseover&quot;)
end</Lua>
<RecastDelay>50</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Dispell</Name>
<Default>false</Default>
<SpellID>2782</SpellID>
<Actions></Actions>
<Lua>local greencauldron = UnitDebuffID(PQR_CustomTarget, 96328)
local bluecauldron = UnitDebuffID(PQR_CustomTarget, 96325)
local redcauldron = UnitDebuffID(PQR_CustomTarget, 96326)
local blackout10 = UnitDebuffID(PQR_CustomTarget, 92876)
local blackout25 = UnitDebuffID(PQR_CustomTarget, 92878)
local unstableaf = UnitDebuffID(PQR_CustomTarget, 30108)
local VT = UnitDebuffID(PQR_CustomTarget, 34941)
if greencauldron or bluecauldron or redcauldron or blackout10 or blackout25 or unstableaf or VT then
return false
else
for i=1,40 do
local _,_,_,count,ismagic,duration = UnitDebuff(mytarget,i)
if ismagic == &quot;Magic&quot; or ismagic == &quot;Disease&quot; or ismagic == &quot;Poison&quot; then
if duration &gt; 6 and count ~= 1 then
return true
end
end
end
end</Lua>
<RecastDelay>0</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>Thorns</Name>
<Default>false</Default>
<SpellID>467</SpellID>
<Actions></Actions>
<Lua>local friend = UnitIsFriend(&quot;player&quot;,&quot;target&quot;)
local mytarget = 100 * UnitHealth(&quot;target&quot;) / UnitHealthMax(&quot;target&quot;)
if friend ~= nil and mytarget &lt; 95 then
return true
end</Lua>
<RecastDelay>0</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
<Ability>
<Name>rejuv self</Name>
<Default>false</Default>
<SpellID>774</SpellID>
<Actions></Actions>
<Lua>local unithealth = 100 * UnitHealth(&quot;target&quot;) / UnitHealthMax(&quot;target&quot;)
if unithealth &lt;= 70 then
return true
end</Lua>
<RecastDelay>0</RecastDelay>
<Target>Target</Target>
<CancelChannel>False</CancelChannel>
<LuaBefore></LuaBefore>
<LuaAfter></LuaAfter>
</Ability>
</DRUID>