diff --git a/BuffsDebuffs.lua b/BuffsDebuffs.lua index 07c15e4..2515371 100644 --- a/BuffsDebuffs.lua +++ b/BuffsDebuffs.lua @@ -627,6 +627,8 @@ rockgrove.oaxiltso_savage_blitz = { } -- Oaxiltso's Noxious Sludge rockgrove.oaxiltso_noxious_sludge = 157860 +-- Havocrel Annihilator's Cinder Cleave at the fight with Oaxiltso +rockgrove.oaxiltso_annihilator_cinder_cleave = 152688 -- Radiating Heat (player gains this effect while Prime Meteor is present) rockgrove.meteor_radiating_heat = { [152462] = true, -- on trash diff --git a/RaidNotifier.lua b/RaidNotifier.lua index f7c0b9c..4081fce 100644 --- a/RaidNotifier.lua +++ b/RaidNotifier.lua @@ -5,7 +5,7 @@ local RaidNotifier = RaidNotifier RaidNotifier.Name = "RaidNotifier" RaidNotifier.DisplayName = "Raid Notifier" -RaidNotifier.Version = "2.19.1" +RaidNotifier.Version = "2.20" RaidNotifier.Author = "|c009ad6Kyoma, Memus, Woeler, silentgecko|r" RaidNotifier.SV_Name = "RNVars" RaidNotifier.SV_Version = 4 @@ -630,12 +630,14 @@ do ---------------------- dbg("Register for %s (%s)", GetRaidZoneName(self.raidId), GetString("SI_DUNGEONDIFFICULTY", self.raidDifficulty)) local trial = self.Trial[self.raidId] + local combatStateChangedCallback + if (trial) then trial.Initialize() local combatEventCallback = trial.OnCombatEvent local bossesChangedCallback = trial.OnBossesChanged local effectChangedCallback = trial.OnEffectChanged - local combatStateChangedCallback = trial.OnCombatStateChanged + combatStateChangedCallback = trial.OnCombatStateChanged local abilityList = {} local function RegisterForAbility(abId) @@ -745,6 +747,13 @@ do ---------------------- EVENT_MANAGER:UnregisterForEvent(self.Name, EVENT_BOSSES_CHANGED) EVENT_MANAGER:UnregisterForEvent(self.Name, EVENT_PLAYER_COMBAT_STATE) + local trial = self.Trial[self.raidId] + + -- Remove custom handlers which may have been assigned inside the trial "class" + if type(trial.Shutdown) == "function" then + trial.Shutdown() + end + --self:RemoveFragment() self:HideAllElements() listening = false diff --git a/RaidNotifier.txt b/RaidNotifier.txt index 83250b5..1c74010 100644 --- a/RaidNotifier.txt +++ b/RaidNotifier.txt @@ -1,7 +1,7 @@ ## Title: |cEFEBBERaidNotifier|r ## Description: Displays on-screen notifications on different events during trials. ## Author: |c009ad6Kyoma, Memus, Woeler, silentgecko|r -## Version: 2.19.1 +## Version: 2.20 ## APIVersion: 101032 ## SavedVariables: RNVars RN_DEBUG_LOG ## DependsOn: LibAddonMenu-2.0>=28 LibUnits2 diff --git a/Settings.lua b/Settings.lua index f0bbc85..c67ad86 100644 --- a/Settings.lua +++ b/Settings.lua @@ -312,6 +312,7 @@ do ------------------ havocrel_barbarian_hasted_assault = false, oaxiltso_savage_blitz = false, oaxiltso_noxious_sludge = 0, -- "Off" + oaxiltso_annihilator_cinder_cleave = 0, -- "Off" bahsei_embrace_of_death = 0, -- "Off" }, dbg = { @@ -559,6 +560,7 @@ function RaidNotifier:CreateSettingsMenu() rockgrove = { sulxan_reaver_sundering_strike = off_self_all, oaxiltso_noxious_sludge = off_self_all, + oaxiltso_annihilator_cinder_cleave = off_self_all, bahsei_embrace_of_death = off_self_all, }, } @@ -1683,6 +1685,12 @@ function RaidNotifier:CreateSettingsMenu() tooltip = L.Settings_Rockgrove_Noxious_Sludge_TT, choices = choices.rockgrove.oaxiltso_noxious_sludge, }, "rockgrove", "oaxiltso_noxious_sludge") + MakeControlEntry({ + type = "dropdown", + name = L.Settings_Rockgrove_Cinder_Cleave, + tooltip = L.Settings_Rockgrove_Cinder_Cleave_TT, + choices = choices.rockgrove.oaxiltso_annihilator_cinder_cleave, + }, "rockgrove", "oaxiltso_annihilator_cinder_cleave") MakeControlEntry({ type = "dropdown", name = L.Settings_Rockgrove_Embrace_Of_Death, diff --git a/TrialAsylumSanctorium.lua b/TrialAsylumSanctorium.lua index 0db3033..8c24a7c 100644 --- a/TrialAsylumSanctorium.lua +++ b/TrialAsylumSanctorium.lua @@ -11,10 +11,16 @@ local data = {} function RaidNotifier.AS.Initialize() p = RaidNotifier.p dbg = RaidNotifier.dbg - + data = {} end +function RaidNotifier.AS.Shutdown() + -- In case of zoning out during the battle "OnCombatStateChanged" handler may be unregistered before it'll be called + -- outside the combat; so we have to manually unregister handler for interval check here + EVENT_MANAGER:UnregisterForUpdate(RaidNotifier.Name .. "_IntervalCheck") +end + local function OnIntervalCheck() local self = RaidNotifier local raidId = RaidNotifier.raidId @@ -22,7 +28,12 @@ local function OnIntervalCheck() local settings = self.Vars.asylum if (settings.olms_gusts_of_steam and settings.olms_gusts_of_steam_slider > 0) then - health, maxHealth = GetUnitPower("boss1", POWERTYPE_HEALTH) -- Llothi + local health, maxHealth = GetUnitPower("boss1", POWERTYPE_HEALTH) -- It's always Olms in AS + -- Precautious check in case of situation when the fight is finished already but the combat state check didn't fire yet + -- (as we have 3 seconds delay for that currently) + if (health == 0 or maxHealth == 0) then + return + end local healthPercent = health * 100 / maxHealth if (data.olmsHealthChecked == nil) then data.olmsHealthChecked = healthPercent @@ -40,6 +51,8 @@ end function RaidNotifier.AS.OnCombatStateChanged(inCombat) local self = RaidNotifier if (inCombat) then + -- At the start of the fight we want to clear all previous fight data collected + data = {} EVENT_MANAGER:RegisterForUpdate(self.Name .. "_IntervalCheck", 1000, OnIntervalCheck); dbg("start interval check") else diff --git a/TrialRockgrove.lua b/TrialRockgrove.lua index 23bb854..6ac8fba 100644 --- a/TrialRockgrove.lua +++ b/TrialRockgrove.lua @@ -100,6 +100,13 @@ function RaidNotifier.RG.OnCombatEvent(_, result, isError, aName, aGraphic, aAct if (settings.oaxiltso_savage_blitz and tName ~= "") then self:AddAnnouncement(zo_strformat(GetString(RAIDNOTIFIER_ALERTS_ROCKGROVE_SAVAGE_BLITZ), tName), "rockgrove", "oaxiltso_savage_blitz") end + -- Havocrel Annihilator's Cinder Cleave at the fight with Oaxiltso + elseif (abilityId == buffsDebuffs.oaxiltso_annihilator_cinder_cleave) then + if (settings.oaxiltso_annihilator_cinder_cleave >= 1 and tType == COMBAT_UNIT_TYPE_PLAYER) then + self:AddAnnouncement(GetString(RAIDNOTIFIER_ALERTS_ROCKGROVE_CINDER_CLEAVE), "rockgrove", "oaxiltso_annihilator_cinder_cleave") + elseif (settings.oaxiltso_annihilator_cinder_cleave == 2 and tName ~= "") then + self:AddAnnouncement(zo_strformat(GetString(RAIDNOTIFIER_ALERTS_ROCKGROVE_CINDER_CLEAVE_OTHER), tName), "rockgrove", "oaxiltso_annihilator_cinder_cleave") + end end elseif (result == ACTION_RESULT_EFFECT_FADED) then -- Sul-Xan Soulweaver's Soul Remnant attack (his Astral Shield is broken) diff --git a/lang/de.lua b/lang/de.lua index 8cc99fd..a93f942 100644 --- a/lang/de.lua +++ b/lang/de.lua @@ -405,7 +405,7 @@ L.Alerts_Asylum_Teleport_Strike_Other = "|cFF3366Teleportationsschlag L.Alerts_Asylum_Exhaustive_Charges = "Eingehende |cFF0000Erschöpfende Ladungen|r" L.Alerts_Asylum_Storm_The_Heavens = "Eingehende |cFF0000Erstürmung des Himmels|r! Kite!" L.Alerts_Asylum_Gusts_Of_Steam = "Eingehende |cFF9900Dampfschwaden|r! Verstecken!" -L.Alerts_Asylum_Pre_Gusts_Of_Steam = "<<1>> vor |cFF0000Sprung|r! Bereit zu Laufen!" +L.Alerts_Asylum_Pre_Gusts_Of_Steam = "|cFF0000<<1>>%|r vor |cFF9900Sprung|r! Bereit zu Laufen!" L.Alerts_Asylum_Trial_By_Fire = "Eingehendes |cFF5500Feuer|r!" L.Alerts_Asylum_Protector_Spawn = "|c0000FFGeschütz|r erscheint!" L.Alerts_Asylum_Protector_Active = "|c0000FFGeschütz|r aktiv!" diff --git a/lang/en.lua b/lang/en.lua index 6b98bd4..c77d814 100644 --- a/lang/en.lua +++ b/lang/en.lua @@ -414,7 +414,7 @@ L.Alerts_Asylum_Teleport_Strike_Other = "|cFF3366Teleport Strike|r on L.Alerts_Asylum_Exhaustive_Charges = "Incoming |cFF0000Exhaustive Charges|r" L.Alerts_Asylum_Storm_The_Heavens = "Incoming |cFF0000Storm The Heavens|r! Kite!" L.Alerts_Asylum_Gusts_Of_Steam = "Incoming |cFF9900Gusts Of Steam|r! Hide!" -L.Alerts_Asylum_Pre_Gusts_Of_Steam = "<<1>> to |cFF0000jump|r! Prepare to Hide!" +L.Alerts_Asylum_Pre_Gusts_Of_Steam = "|cFF0000<<1>>%|r to |cFF9900jump|r! Prepare to Hide!" L.Alerts_Asylum_Trial_By_Fire = "Incoming |cFF5500Fire|r!" L.Alerts_Asylum_Protector_Spawn = "|c0000FFProtector|r spawning!" L.Alerts_Asylum_Protector_Active = "|c0000FFProtector|r active!" @@ -570,7 +570,7 @@ L.Settings_KynesAegis_Ichor_Eruption_CD_Time_TT = "Time before Ichor Eruptio -- Alerts L.Alerts_KynesAegis_Crashing_Wall = "|cd2a100Crashing Wall|r in" -L.Alerts_KynesAegis_Sanguine_Prison_Other = "|cff0000<>|r trapped in |cb00000Sanguine Prison|r. Free him!" +L.Alerts_KynesAegis_Sanguine_Prison_Other = "|cff0000<>|r trapped in |cb00000Sanguine Prison|r. Free them!" L.Alerts_KynesAegis_Blood_Fountain = "|cb00000Blood Fountain|r in" L.Alerts_KynesAegis_Dragon_Totem = "Two |cffa500Dragon Totems|r spawned. Avoid the fire!" L.Alerts_KynesAegis_Harpy_Totem = "|c00bfffHarpy Totem|r spawned." @@ -600,6 +600,8 @@ L.Settings_Rockgrove_Savage_Blitz = "Oaxiltso: Savage Blitz" L.Settings_Rockgrove_Savage_Blitz_TT = "Alerts you when the Oaxiltso charges at the furthest player." L.Settings_Rockgrove_Noxious_Sludge = "Oaxiltso: Noxious Sludge" L.Settings_Rockgrove_Noxious_Sludge_TT = "Alerts you when someone is poisoned by Oaxiltso and has to go cleanse in the pool." +L.Settings_Rockgrove_Cinder_Cleave = "Oaxiltso's mini-boss: Cinder Cleave" +L.Settings_Rockgrove_Cinder_Cleave_TT = "Alerts you when Havocrel Annihilator casts his Cinder Cleave ability on someone during the fight with Oaxiltso." L.Settings_Rockgrove_Embrace_Of_Death = "Flame-Herald Bahsei: Embrace of Death" L.Settings_Rockgrove_Embrace_Of_Death_TT = "Alerts you when someone got cursed by Flame-Herald Bahsei. That person will explode after 8 seconds, spreading the curse. It's important to keep cursed player separated from the group." L.Settings_Rockgrove_Embrace_Of_Death_TT_All = "|cFF0000WARNING!|r If your group will get too much curses your screen may be fully covered in countdowns for a duration of those curses! We're working on ways to improve this notification." @@ -615,8 +617,10 @@ L.Alerts_Rockgrove_Savage_Blitz = "Oaxiltso charges at |cFF00 L.Alerts_Rockgrove_Noxious_Sludge_Self = "You're poisoned by |c008C22Noxious Sludge|r! Cleanse in the pool!" L.Alerts_Rockgrove_Noxious_Sludge_Other1 = "|cFF0000<>|r is poisoned by |c008C22Noxious Sludge|r." L.Alerts_Rockgrove_Noxious_Sludge_Other2 = "|cFF0000<>|r and |cFF0000<>|r are poisoned by |c008C22Noxious Sludge|r." -L.Alerts_Rockgrove_Embrace_Of_Death = "You're cursed by |c370073Embrace of Death|r! Stay away! Explosion in" -L.Alerts_Rockgrove_Embrace_Of_Death_Other = "|cFF0000<>|r cursed by |c370073Embrace of Death|r! Explosion in" +L.Alerts_Rockgrove_Cinder_Cleave = "|cD74700Cinder Cleave|r on you!" +L.Alerts_Rockgrove_Cinder_Cleave_Other = "|cD74700Cinder Cleave|r on |cFF0000<>|r." +L.Alerts_Rockgrove_Embrace_Of_Death = "You're cursed by |c0A929BEmbrace of Death|r! Stay away! Explosion in" +L.Alerts_Rockgrove_Embrace_Of_Death_Other = "|cFF0000<>|r cursed by |c0A929BEmbrace of Death|r! Explosion in" -------------------------------- diff --git a/lang/es.lua b/lang/es.lua index 87d8dd4..8efe610 100644 --- a/lang/es.lua +++ b/lang/es.lua @@ -416,7 +416,7 @@ L.Alerts_Asylum_Teleport_Strike_Other = "|cFF3366 Golpe de transporta L.Alerts_Asylum_Exhaustive_Charges = "|cFF0000Cargas agotadoras|r inminente." L.Alerts_Asylum_Storm_The_Heavens = "¡|cFF0000Asalto desde los Cielos|r inminente! ¡Aléjate lentamente!" L.Alerts_Asylum_Gusts_Of_Steam = "¡|cFF9900Ráfagas de vapor|r inminente! ¡Escóndete!" -L.Alerts_Asylum_Pre_Gusts_Of_Steam = "¡<<1>> va a |cFF0000saltar|r! ¡Preparate para esconderte!" +L.Alerts_Asylum_Pre_Gusts_Of_Steam = "¡|cFF0000<<1>>%|r va a |cFF9900saltar|r! ¡Preparate para esconderte!" L.Alerts_Asylum_Trial_By_Fire = "¡|cFF5500Fuego|r inminente!" L.Alerts_Asylum_Protector_Spawn = "¡|c0000FFProtector|r apareciendo!" L.Alerts_Asylum_Protector_Active = "¡|c0000FFProtector|r activo!" diff --git a/lang/fr.lua b/lang/fr.lua index 61b42cb..19e9bd9 100644 --- a/lang/fr.lua +++ b/lang/fr.lua @@ -398,7 +398,7 @@ L.Alerts_Asylum_Teleport_Strike_Other = "|cFF3366Téléportation|r su L.Alerts_Asylum_Exhaustive_Charges = "En Approche |cFF0000Charges Épuisantes|r" L.Alerts_Asylum_Storm_The_Heavens = "En Approche |cFF0000Assaillir les Cieux|r! Courez!" L.Alerts_Asylum_Gusts_Of_Steam = "En Approche |cFF9900Nuages de Vapeur|r! Cachez vous!" -L.Alerts_Asylum_Pre_Gusts_Of_Steam = "<<1>>% avant |cFF0000Saut|r! Préparez vous!" +L.Alerts_Asylum_Pre_Gusts_Of_Steam = "|cFF0000<<1>>%|r avant |cFF9900Saut|r! Préparez vous!" L.Alerts_Asylum_Trial_By_Fire = "En Approche |cFF5500Feu|r!" L.Alerts_Asylum_Protector_Spawn = "Apparition d'un |c0000FFProtecteur|r!" L.Alerts_Asylum_Protector_Active = "|c0000FFProtecteur|r actif!" diff --git a/lang/ru.lua b/lang/ru.lua index aed59f0..e180289 100644 --- a/lang/ru.lua +++ b/lang/ru.lua @@ -398,6 +398,7 @@ L.Alerts_Asylum_Storm_The_Heavens = "Приближается |cF L.Alerts_Asylum_Eruption = "|c595959Eruption|r нацелена на тебя!" L.Alerts_Asylum_Eruption_Other = "|c595959Eruption|r нацелена на игрока |cFC0000<>|r!" L.Alerts_Asylum_Gusts_Of_Steam = "Приближается |cFF9900Gusts Of Steam|r! СПРЯЧЬСЯ!" +L.Alerts_Asylum_Pre_Gusts_Of_Steam = "|cFF0000<<1>>%|r до |cFF9900прыжка|r! ГОТОВЬСЯ прятаться!" L.Alerts_Asylum_Trial_By_Fire = "Приближается |cFF5500Fire|r!" L.Alerts_Asylum_Protector_Spawn = "Появляется |c0000FFЗащитник|r!" L.Alerts_Asylum_Protector_Active = "|c0000FFЗащитник|r активирован!"