Hey everyone, let me preface this with the fact that I have zero knowledge of LUA and I'm drawing on what little experience I have in programming.
I've got a question regarding feral druid dps and berserk. Currently I'm using Googlebees because it yields the highest DPS for me and I've noticed repeatedly that it would cast Berserk before reaching Tiger's fury every time. It waits for Tiger's Fury to become available, and then it procs Berserk before Tiger's Fury and wasting essentially an entire TIger's Fury cast. (For feral dps, it's generally a better idea to use Tiger's Fury DIRECTLY BEFORE you use Berserk.)
Here is the default code for Tiger's Fury.
Code:
<RecastDelay>0</RecastDelay><Target>Target</Target><CancelChannel>False</CancelChannel><SkipUnknown>True</SkipUnknown></Ability><Ability><Name>CAT Tigers Fury</Name><Default>false</Default><SpellID>5217</SpellID><Actions>/use Berserk | /use Berserking</Actions><Lua>
local _,_,_,TF = UnitBuffID(&quot;player&quot;, 5217)
local TFstart, TFduration = GetSpellCooldown(5217)
local TFcooldown = (TFstart + TFduration - GetTime())
local tfEnergy = UnitPower(&quot;player&quot;) / UnitPowerMax(&quot;player&quot;) * 100
if TF ~= nil then
return false
else
if TFcooldown &gt; 0 then
return false
else
if tfEnergy &lt; 40 then
return true
end
end
end
So essentially what it seems to be doing is if Tiger's Fury would become active, it first calls "/use Berserk" and then locks out Tiger's Fury for the duration of the Berserk.
Here is my modified LUA code that I've gotten to work where Berserk will only become active immediately after Tiger's Fury would normally be used.
Code:
<RecastDelay>0</RecastDelay><Target>Target</Target><CancelChannel>False</CancelChannel><SkipUnknown>True</SkipUnknown></Ability><Ability><Name>CAT Tigers Fury</Name><Default>false</Default><SpellID>5217</SpellID><Actions></Actions><Lua>
local _,_,_,TF = UnitBuffID(&quot;player&quot;, 5217)
local TFstart, TFduration = GetSpellCooldown(5217)
local TFcooldown = (TFstart + TFduration - GetTime())
local tfEnergy = UnitPower(&quot;player&quot;) / UnitPowerMax(&quot;player&quot;) * 100
if TF ~= nil then
return false
else
if TFcooldown &gt; 0 then
return false
else
if tfEnergy &lt; 40 then
CastSpellByName(tostring(GetSpellInfo(5217))) --If Tiger's Fury meets the requirements then Cast Tiger's Fury from within the function/method using the toString.
CastSpellByName(tostring(GetSpellInfo(50334))) --Immediately after attempt to cast Berserk using the toString function/method.
return true
end
end
end
Here are my questions (I realize I could just google these, but I would like the input of other power users.) :
1. Is it viable to call Tiger's Fury using the ToString method/function if it would cast the spell again when it reaches 'return true'.
2. Since I assume it's calling Tiger's Fury two times instead of just once, (ToString and return true) is there anyway to wrap those method/function calls so they do not display error text on screen when berserk can't be used but Tiger's Fury is available.
Would I simply need to shimmy in another if statement that checks the cooldown of berserk and either casts both TIger's Fury and Berserk or just cast Tiger's Fury.
I apologize for the incredibly long post, but It's 9:30 AM and I've been up for over 24 hours. I apologize for my ineptitude.