Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function (event, ...)
- local isFinisher, isCombo, fcpId
- WA_feralCP_spellIDs = WA_feralCP_spellIDs or {
- --SPELL_DAMAGE
- {5221, "addCombo_pf"}, -- [1] Shred
- {114236, "addCombo_pf"}, -- [2] Shred!
- {33876, "addCombo_pf"}, -- [3] Mangle
- {6785, "addCombo_pf"}, -- [4] Ravage
- {102545, "addCombo_pf"}, -- [5] Ravage!
- {22568, "spendCombo"}, -- [6] Ferocious Bite
- {62078, "addCombo_aoe"}, -- [7] Swipe
- --SPELL_CAST_SUCCESS
- {1822, "addCombo_pf"}, -- [8] Rake
- {1079, "spendCombo"}, -- [9] Rip
- {127538, "spendCombo"}, -- [10] Savage Roar
- }
- WA_feralCP_count = WA_feralCP_count or 0
- WA_feralCP_GCD = WA_feralCP_GCD or 0
- if event == "COMBAT_LOG_EVENT_UNFILTERED" then
- local _, cleuevent, hideCaster, sourceGUID, sourceName, _, _, destGUID, destName = ...
- if sourceGUID == UnitGUID("player") then
- if cleuevent == "SPELL_DAMAGE" then
- local _, _, _, _, _, _, _, _, _, _, _, spellId = ...
- for i=1,7 do
- if spellId == WA_feralCP_spellIDs[i][1] then fcpId = i end
- end
- elseif cleuevent == "SPELL_CAST_SUCCESS" then
- local _, _, _, _, _, _, _, _, _, _, _, spellId = ...
- for i=8,10 do
- if spellId == WA_feralCP_spellIDs[i][1] then fcpId = i end
- end
- end
- if fcpId ~= nil then
- if WA_feralCP_spellIDs[fcpId][2] == "addCombo_pf" then
- WA_feralCP_target = destGUID
- local _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, _, critical = ...
- print(critical)
- if critical == 1 then
- WA_feralCP_count = WA_feralCP_count + 1
- print(GetTime()..": "..WA_feralCP_count)
- else
- --WA_feralCP_count = WA_feralCP_count + 1
- end
- elseif WA_feralCP_spellIDs[fcpId][2] == "spendCombo" then
- WA_feralCP_target = nil
- WA_feralCP_count = 0
- elseif WA_feralCP_spellIDs[fcpId][2] == "addCombo_aoe" then
- if WA_feralCP_target == nil and destGUID == UnitGUID("target") or destGUID == WA_feralCP_target then
- WA_feralCP_target = destGUID
- --WA_feralCP_count = WA_feralCP_count + 1
- end
- end
- end
- end
- elseif event == "UNIT_COMBO_POINTS" then
- local unit = ...
- if unit == "player" then
- local start = GetSpellCooldown("Shred")
- if start ~= WA_feralCP_GCD then
- WA_feralCP_count = GetComboPoints("player", "target")
- print(GetTime()..": "..WA_feralCP_count)
- end
- WA_feralCP_GCD = start
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment