From 7d3a9a459d9ba653c39f7f8d9caffb0a2f6ea66d Mon Sep 17 00:00:00 2001 From: BillLive Date: Sun, 31 Jan 2016 13:51:59 +1030 Subject: [PATCH] Enabled checking of FlameShockBehaviour Flag in rotation Renamed doFS to boostFSpriority Signed-off-by: BillLive --- Elementarist.toc | 3 --- modules/elemental.lua | 29 +++++++++++++++-------------- 2 files changed, 15 insertions(+), 17 deletions(-) diff --git a/Elementarist.toc b/Elementarist.toc index 82f3b4a..63a35f1 100755 --- a/Elementarist.toc +++ b/Elementarist.toc @@ -6,9 +6,6 @@ ## SavedVariables: ElementaristDB ## OptionalDeps: OmniCC, SpellFlash ## Dependencies: -## X-Curse-Project-Name: Elementarist -## X-Curse-Project-ID: elementarist -## X-Curse-Repository-ID: wow/elementarist/mainline Elementarist.lua Ele_GUI.lua diff --git a/modules/elemental.lua b/modules/elemental.lua index 97a4960..eeccd37 100755 --- a/modules/elemental.lua +++ b/modules/elemental.lua @@ -83,7 +83,7 @@ Elementarist.elemental = { local s,d,e local haveFireTotem,fireTotemName,fireTotemStart,fireTotemDuration local lastSpell - local doFS = false + local boostFSpriority = false local _ local EBTalent = (Elementarist.tier6Talent == 19267) local UFTalent = (Elementarist.tier6Talent == 21773) @@ -198,10 +198,10 @@ Elementarist.elemental = { -- Determine if Flameshock is to be boosted in Priority -- which occurs if the Boosting checking based on configuration and if they have the relevant talent to boost the DOT, -- boost if any available boost is missing or if the time remaining is less than the configured threshold - if (ElementaristDB.maximizeFS) and (UFTalent) and (Elementarist.auraCooldowns[tguid] and Elementarist.auraCooldowns[tguid]["BuffCount1"] ~= 1 ) then doFS = true end - if (ElementaristDB.maximizeFS) and (EFTalent) and (Elementarist.auraCooldowns[tguid] and Elementarist.auraCooldowns[tguid]["BuffCount2"] ~= 2 ) then doFS = true end - if ElementaristDB.doFSThreshold > (fsExpiration - currentTime - timeshift) then doFS = true end - if doFS then Elementarist:Debug("doFS ufCount:" .. ufCount, " efCount"..efCount) else Elementarist:Debug("----- ufCount:" .. ufCount, " efCount"..efCount) end + if (ElementaristDB.maximizeFS) and (UFTalent) and (Elementarist.auraCooldowns[tguid] and Elementarist.auraCooldowns[tguid]["BuffCount1"] ~= 1 ) then boostFSpriority = true end + if (ElementaristDB.maximizeFS) and (EFTalent) and (Elementarist.auraCooldowns[tguid] and Elementarist.auraCooldowns[tguid]["BuffCount2"] ~= 2 ) then boostFSpriority = true end + if ElementaristDB.doFSThreshold > (fsExpiration - currentTime - timeshift) then boostFSpriority = true end + if boostFSpriority then Elementarist:Debug("boostFSpriority ufCount:" .. ufCount, " efCount"..efCount) else Elementarist:Debug("----- ufCount:" .. ufCount, " efCount"..efCount) end ----------------------------------------------------- @@ -313,7 +313,7 @@ Elementarist.elemental = { -- Only allow this if we are not boosting Flameshock priority if (Elementarist:ZeroCount(Elementarist.SpellList["Flame Shock"],spellInCast,exspell1,exspell2) and Elementarist:ZeroCount(Elementarist.SpellList["Earth Shock"],spellInCast,exspell1,exspell2)) and - not (doFS) then + not (boostFSpriority) then if ( (fsExpiration - GetTime() - timeshift) > Elementarist.lastShockCD ) then d = Elementarist:GetSpellCooldownRemaining(Elementarist.SpellList["Earth Shock"]) if ( @@ -331,16 +331,17 @@ Elementarist.elemental = { -- Priority 6 -- Flameshock if not present or at less than 30% duration -- lame_shock,cycle_targets=1,if=dot.flame_shock.remains<=(dot.flame_shock.duration*0.3) - if (Elementarist:ZeroCount(Elementarist.SpellList["Flame Shock"],spellInCast,exspell1,exspell2) ) and - (Elementarist:ZeroCount(Elementarist.SpellList["Earth Shock"],spellInCast,exspell1,exspell2) ) then - d = Elementarist:GetSpellCooldownRemaining(Elementarist.SpellList["Flame Shock"]) - if ((d - timeshift) <= 0) then - if ((fsExpiration - GetTime() - timeshift) < (9) ) then - return Elementarist.SpellList["Flame Shock"] + if (ElementaristDB.Behavior == Elementarist.Behaviors["1"]) or (lvbCharges > 0) then + if (Elementarist:ZeroCount(Elementarist.SpellList["Flame Shock"],spellInCast,exspell1,exspell2) ) and + (Elementarist:ZeroCount(Elementarist.SpellList["Earth Shock"],spellInCast,exspell1,exspell2) ) then + d = Elementarist:GetSpellCooldownRemaining(Elementarist.SpellList["Flame Shock"]) + if ((d - timeshift) <= 0) then + if ((fsExpiration - GetTime() - timeshift) < (9) ) then + return Elementarist.SpellList["Flame Shock"] + end end end end - -- Priority 6b -- Lava Burst if Ascendance but not able to flame shock..you should never get here!!.. Flameshock before you Assend! if ( (ascendanceExp-GetTime()-timeshift) > 0) and @@ -364,7 +365,7 @@ Elementarist.elemental = { -- Priority 8 -- If Tier6 talent is Unleashed Fury cast Unleash Flame or (buffs & cooldowns & reamaining time are correct) -- Unleash_flame,if=talent.unleashed_fury.enabled&!buff.ascendance.up|(talent.elemental_fusion.enabled&buff.elemental_fusion.stack=2&(dot.flame_shock.remains)<(dot.flame_shock.duration*(0.3+t18_class_trinket*(0.48+talent.unleashed_fury.enabled*0.22)))&cooldown.flame_shock.remains Elementarist.lastShockCD) ) then if (Elementarist:ZeroCount(Elementarist.SpellList["Unleash Flame"],spellInCast,exspell1,exspell2) ) then d = Elementarist:GetSpellCooldownRemaining(Elementarist.SpellList["Unleash Flame"]) -- 1.7.9.5