Skip to content

Commit

Permalink
superwow: ignore buff procs during cast
Browse files Browse the repository at this point in the history
  • Loading branch information
shagu committed Aug 10, 2024
1 parent ada9ee9 commit 860538e
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion modules/superwow.lua
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,16 @@ pfUI:RegisterModule("superwow", "vanilla", function ()
spell = spell or UNKNOWN
icon = icon or "Interface\\Icons\\INV_Misc_QuestionMark"

-- skip on buff procs during cast
if event_type == "CAST" then
if not libcast.db[guid] or libcast.db[guid].cast ~= spell then
-- ignore casts without 'START' event, while there is already another cast.
-- those events can be for example a frost shield proc while casting frostbolt.
-- we want to keep the cast itself, so we simply skip those.
return
end
end

-- add cast action to the database
if not libcast.db[guid] then libcast.db[guid] = {} end
libcast.db[guid].cast = spell
Expand All @@ -48,4 +58,4 @@ pfUI:RegisterModule("superwow", "vanilla", function ()
end
end
end)
end)
end)

0 comments on commit 860538e

Please sign in to comment.