From a731143de88ad211b59658242c6d95ce8a85e470 Mon Sep 17 00:00:00 2001 From: pepopo978 Date: Mon, 12 Jan 2026 17:53:08 -0800 Subject: [PATCH] improve handling of malediction --- Cursive.toc | 4 ++-- README.md | 2 ++ curses.lua | 14 ++++++++++++++ 3 files changed, 18 insertions(+), 2 deletions(-) diff --git a/Cursive.toc b/Cursive.toc index 25d683a..42bda09 100644 --- a/Cursive.toc +++ b/Cursive.toc @@ -1,6 +1,6 @@ ## Interface: 11200 -## Title: [|CFF33AAFFSUPERWOW|R] Cursive 2.6.1 -## Title-zhCN: [|CFF33AAFFSUPERWOW|R] Cursive 2.6.1 +## Title: [|CFF33AAFFSUPERWOW|R] Cursive 2.6.2 +## Title-zhCN: [|CFF33AAFFSUPERWOW|R] Cursive 2.6.2 ## Author: Pepopo ## Notes: Uses SuperWoW GUIDs to show units in combat and track curses ## Notes-zhCN: 使用SuperWoW的GUID功能来显示战斗中的单位并监视诅咒等 diff --git a/README.md b/README.md index f5c5243..6a1773c 100644 --- a/README.md +++ b/README.md @@ -187,6 +187,8 @@ All commands will ignore targets with the following CCs on them: Multicurse will only ever target enemies that are already in combat (except if you target a mob directly first) to prevent pulling things you didn't intend like marked patrols. +For Warlocks with the Malediction talent, when checking if Curse of Recklessness, Curse of the Elements, or Curse of Shadow is already on a target, the addon will instead check for Curse of Agony to allow you to refresh agony using them. Don't use the refreshtime option with this as the server won't refresh Curse of Agony if it is still on the mob. + Mobs with raid marks will be displayed first. Mobs will the top 3 max hps will always display next. I may make this configurable in the future. diff --git a/curses.lua b/curses.lua index d32cd40..51dd6c6 100644 --- a/curses.lua +++ b/curses.lua @@ -585,8 +585,22 @@ function curses:HasCurse(lowercaseSpellNameNoRank, targetGuid, minRemaining) lowercaseSpellNameNoRank = L["faerie fire"] end + -- handle malediction for warlocks + if curses.isWarlock and + lowercaseSpellNameNoRank == L["curse of recklessness"] or + lowercaseSpellNameNoRank == L["curse of the elements"] or + lowercaseSpellNameNoRank == L["curse of shadow"] then + -- check if they have malediction + local _, _, _, _, malediction = GetTalentInfo(1, 17) + + if malediction > 0 then + lowercaseSpellNameNoRank = L["curse of agony"] -- check for curse of agony instead + end + end + if curses.guids[targetGuid] and curses.guids[targetGuid][lowercaseSpellNameNoRank] then local remaining = Cursive.curses:TimeRemaining(curses.guids[targetGuid][lowercaseSpellNameNoRank]) + if remaining >= minRemaining then return true end