diff --git a/Delves/NightfallSanctum/CultLeaders.lua b/Delves/NightfallSanctum/CultLeaders.lua new file mode 100644 index 000000000..718a93d63 --- /dev/null +++ b/Delves/NightfallSanctum/CultLeaders.lua @@ -0,0 +1,152 @@ +-------------------------------------------------------------------------------- +-- Module Declaration +-- + +local mod, CL = BigWigs:NewBoss("Cult Leaders", 2686) +if not mod then return end +mod:RegisterEnableMob( + 229854, -- Inquisitor Speaker + 229855, -- Shadeguard Speaker + 230904 -- Shadeguard Speaker +) +mod:SetEncounterID(3050) +mod:SetRespawnTime(15) +mod:SetAllowWin(true) + +-------------------------------------------------------------------------------- +-- Locals +-- + +local bossCollector = {} +local bossesEngaged = 0 + +-------------------------------------------------------------------------------- +-- Localization +-- + +local L = mod:GetLocale() +if L then + L.cult_leaders = "Cult Leaders" + L.inquisitor_speaker = "Inquisitor Speaker" + L.shadeguard_speaker = "Shadeguard Speaker" +end + +-------------------------------------------------------------------------------- +-- Initialization +-- + +function mod:OnRegister() + self.displayName = L.cult_leaders +end + +function mod:GetOptions() + return { + -- Inquisitor Speaker + {434740, "NAMEPLATE"}, -- Shadow Barrier + -- Shadeguard Speaker + {458874, "NAMEPLATE"}, -- Shadow Wave + {443482, "DISPEL", "NAMEPLATE"}, -- Blessing of Dusk + }, { + [434740] = L.inquisitor_speaker, + [458874] = L.shadeguard_speaker, + } +end + +function mod:OnBossEnable() + -- Inquisitor Speaker + self:Log("SPELL_CAST_START", "ShadowBarrier", 434740) + self:Death("InquisitorSpeakerDeath", 229854) + + -- Shadeguard Speaker + self:Log("SPELL_CAST_START", "ShadowWave", 458874) + self:Log("SPELL_CAST_START", "BlessingOfDusk", 443482) + self:Log("SPELL_AURA_APPLIED", "BlessingOfDuskApplied", 443482) + self:Death("ShadeguardSpeakerDeath", 229855, 230904) +end + +function mod:OnEngage() + bossCollector = {} + bossesEngaged = 0 + -- timers started in IEEU + self:RegisterEvent("INSTANCE_ENCOUNTER_ENGAGE_UNIT") +end + +-------------------------------------------------------------------------------- +-- Event Handlers +-- + +function mod:INSTANCE_ENCOUNTER_ENGAGE_UNIT(event) + for i = 1, 3 do + local guid = self:UnitGUID(("boss%d"):format(i)) + if guid and not bossCollector[guid] then + bossCollector[guid] = true + local mobId = self:MobId(guid) + if mobId == 229855 or mobId == 230904 then -- Shadeguard Speaker + bossesEngaged = bossesEngaged + 1 + self:Nameplate(458874, 2.4, guid) -- Shadow Wave + self:Nameplate(443482, 10.6, guid) -- Blessing of Dusk + end + if bossesEngaged == 2 then + -- there are 3 bosses but we only need to start timers for the 2 Shadeguard Speakers. + -- Shadow Barrier is cast by the Inquisitor Speaker on pull. + self:UnregisterEvent(event) + break + end + end + end +end + +-- Inquisitor Speaker + +function mod:ShadowBarrier(args) + -- also cast by trash + if self:MobId(args.sourceGUID) == 229854 then -- Inquisitor Speaker + self:Message(args.spellId, "yellow", CL.casting:format(args.spellName)) + self:Nameplate(args.spellId, 24.0, args.sourceGUID) + self:PlaySound(args.spellId, "info") + end +end + +function mod:InquisitorSpeakerDeath(args) + self:ClearNameplate(args.destGUID) +end + +-- Shadeguard Speaker + +function mod:ShadowWave(args) + self:Message(args.spellId, "orange") + self:Nameplate(args.spellId, 12.1, args.sourceGUID) + self:PlaySound(args.spellId, "alarm") +end + +do + local prev = 0 + function mod:BlessingOfDusk(args) + -- also cast by trash + local mobId = self:MobId(args.sourceGUID) + if mobId == 229855 or mobId == 230904 and args.time - prev > 1.5 then -- Shadeguard Speaker + prev = args.time + self:Message(args.spellId, "red", CL.casting:format(args.spellName)) + self:Nameplate(args.spellId, 25.4, args.sourceGUID) + self:PlaySound(args.spellId, "alert") + end + end +end + +do + local prev = 0 + function mod:BlessingOfDuskApplied(args) + -- also cast by trash + local mobId = self:MobId(args.destGUID) + if (mobId == 229855 or mobId == 230904) and args.time - prev > 2 + and self:Dispeller("magic", true, args.spellId) then -- Shadeguard Speaker + prev = args.time + self:Message(args.spellId, "yellow", CL.on:format(args.spellName, args.destName)) + self:PlaySound(args.spellId, "info") + end + end +end + +function mod:ShadeguardSpeakerDeath(args) + self:ClearNameplate(args.destGUID) +end diff --git a/Delves/NightfallSanctum/Locales/deDE.lua b/Delves/NightfallSanctum/Locales/deDE.lua index d82c6dad2..f25deff15 100644 --- a/Delves/NightfallSanctum/Locales/deDE.lua +++ b/Delves/NightfallSanctum/Locales/deDE.lua @@ -9,3 +9,10 @@ if L then L.speaker_davenruth = "Sprecher Davenruth" L.reformed_fury = "Erneuerter Zorn" end + +L = BigWigs:NewBossLocale("Cult Leaders", "deDE") +if L then + --L.cult_leaders = "Cult Leaders" + --L.inquisitor_speaker = "Inquisitor Speaker" + --L.shadeguard_speaker = "Shadeguard Speaker" +end diff --git a/Delves/NightfallSanctum/Locales/esES.lua b/Delves/NightfallSanctum/Locales/esES.lua index e23633b7a..7501749b0 100644 --- a/Delves/NightfallSanctum/Locales/esES.lua +++ b/Delves/NightfallSanctum/Locales/esES.lua @@ -9,3 +9,10 @@ if L then L.speaker_davenruth = "Oradora Davenruth" L.reformed_fury = "Furia reformada" end + +L = BigWigs:NewBossLocale("Cult Leaders", "esES") +if L then + --L.cult_leaders = "Cult Leaders" + --L.inquisitor_speaker = "Inquisitor Speaker" + --L.shadeguard_speaker = "Shadeguard Speaker" +end diff --git a/Delves/NightfallSanctum/Locales/esMX.lua b/Delves/NightfallSanctum/Locales/esMX.lua index 57f17dabd..4184da620 100644 --- a/Delves/NightfallSanctum/Locales/esMX.lua +++ b/Delves/NightfallSanctum/Locales/esMX.lua @@ -9,3 +9,10 @@ if L then L.speaker_davenruth = "Orador Davenruth" L.reformed_fury = "Furia reformada" end + +L = BigWigs:NewBossLocale("Cult Leaders", "esMX") +if L then + --L.cult_leaders = "Cult Leaders" + --L.inquisitor_speaker = "Inquisitor Speaker" + --L.shadeguard_speaker = "Shadeguard Speaker" +end diff --git a/Delves/NightfallSanctum/Locales/frFR.lua b/Delves/NightfallSanctum/Locales/frFR.lua index 9a5a7bc3a..6fc0ec68c 100644 --- a/Delves/NightfallSanctum/Locales/frFR.lua +++ b/Delves/NightfallSanctum/Locales/frFR.lua @@ -9,3 +9,10 @@ if L then L.speaker_davenruth = "Mandataire Davenruth" L.reformed_fury = "Fureur reconstituée" end + +L = BigWigs:NewBossLocale("Cult Leaders", "frFR") +if L then + --L.cult_leaders = "Cult Leaders" + --L.inquisitor_speaker = "Inquisitor Speaker" + --L.shadeguard_speaker = "Shadeguard Speaker" +end diff --git a/Delves/NightfallSanctum/Locales/itIT.lua b/Delves/NightfallSanctum/Locales/itIT.lua index cdfb0c6b5..66ce8d4c4 100644 --- a/Delves/NightfallSanctum/Locales/itIT.lua +++ b/Delves/NightfallSanctum/Locales/itIT.lua @@ -9,3 +9,10 @@ if L then L.speaker_davenruth = "Oratore Davenruth" L.reformed_fury = "Furia Riformata" end + +L = BigWigs:NewBossLocale("Cult Leaders", "itIT") +if L then + --L.cult_leaders = "Cult Leaders" + --L.inquisitor_speaker = "Inquisitor Speaker" + --L.shadeguard_speaker = "Shadeguard Speaker" +end diff --git a/Delves/NightfallSanctum/Locales/koKR.lua b/Delves/NightfallSanctum/Locales/koKR.lua index 591a7c926..f07dbf1e6 100644 --- a/Delves/NightfallSanctum/Locales/koKR.lua +++ b/Delves/NightfallSanctum/Locales/koKR.lua @@ -9,3 +9,10 @@ if L then L.speaker_davenruth = "대변자 데이븐루스" L.reformed_fury = "재형성된 격노" end + +L = BigWigs:NewBossLocale("Cult Leaders", "koKR") +if L then + --L.cult_leaders = "Cult Leaders" + --L.inquisitor_speaker = "Inquisitor Speaker" + --L.shadeguard_speaker = "Shadeguard Speaker" +end diff --git a/Delves/NightfallSanctum/Locales/ptBR.lua b/Delves/NightfallSanctum/Locales/ptBR.lua index 81719edd6..6188811fe 100644 --- a/Delves/NightfallSanctum/Locales/ptBR.lua +++ b/Delves/NightfallSanctum/Locales/ptBR.lua @@ -9,3 +9,10 @@ if L then L.speaker_davenruth = "Arauto Davenruth" L.reformed_fury = "Fúria Renovada" end + +L = BigWigs:NewBossLocale("Cult Leaders", "ptBR") +if L then + --L.cult_leaders = "Cult Leaders" + --L.inquisitor_speaker = "Inquisitor Speaker" + --L.shadeguard_speaker = "Shadeguard Speaker" +end diff --git a/Delves/NightfallSanctum/Locales/ruRU.lua b/Delves/NightfallSanctum/Locales/ruRU.lua index 2fae54af2..6d5f932c1 100644 --- a/Delves/NightfallSanctum/Locales/ruRU.lua +++ b/Delves/NightfallSanctum/Locales/ruRU.lua @@ -9,3 +9,10 @@ if L then L.speaker_davenruth = "Глашатай Давенрут" L.reformed_fury = "Преобразованная ярость" end + +L = BigWigs:NewBossLocale("Cult Leaders", "ruRU") +if L then + --L.cult_leaders = "Cult Leaders" + --L.inquisitor_speaker = "Inquisitor Speaker" + --L.shadeguard_speaker = "Shadeguard Speaker" +end diff --git a/Delves/NightfallSanctum/Locales/zhCN.lua b/Delves/NightfallSanctum/Locales/zhCN.lua index 53de82efc..ef37a3e38 100644 --- a/Delves/NightfallSanctum/Locales/zhCN.lua +++ b/Delves/NightfallSanctum/Locales/zhCN.lua @@ -9,3 +9,10 @@ if L then L.speaker_davenruth = "代言人达文鲁兹" L.reformed_fury = "重塑之怒" end + +L = BigWigs:NewBossLocale("Cult Leaders", "zhCN") +if L then + --L.cult_leaders = "Cult Leaders" + --L.inquisitor_speaker = "Inquisitor Speaker" + --L.shadeguard_speaker = "Shadeguard Speaker" +end diff --git a/Delves/NightfallSanctum/Locales/zhTW.lua b/Delves/NightfallSanctum/Locales/zhTW.lua index 1baedb5c1..d3bfe38d2 100644 --- a/Delves/NightfallSanctum/Locales/zhTW.lua +++ b/Delves/NightfallSanctum/Locales/zhTW.lua @@ -9,3 +9,10 @@ if L then --L.speaker_davenruth = "Speaker Davenruth" L.reformed_fury = "重構怒影" end + +L = BigWigs:NewBossLocale("Cult Leaders", "zhTW") +if L then + L.cult_leaders = "教徒領袖" + --L.inquisitor_speaker = "Inquisitor Speaker" + --L.shadeguard_speaker = "Shadeguard Speaker" +end diff --git a/Delves/NightfallSanctum/Options/Colors.lua b/Delves/NightfallSanctum/Options/Colors.lua index 205989a80..9a941876d 100644 --- a/Delves/NightfallSanctum/Options/Colors.lua +++ b/Delves/NightfallSanctum/Options/Colors.lua @@ -13,3 +13,9 @@ BigWigs:AddColors("Speaker Halven", { [443840] = "yellow", [443908] = "orange", }) + +BigWigs:AddColors("Cult Leaders", { + [434740] = "yellow", + [443482] = {"red","yellow"}, + [458874] = "orange", +}) diff --git a/Delves/NightfallSanctum/Options/Sounds.lua b/Delves/NightfallSanctum/Options/Sounds.lua index 91764403c..8c61bd448 100644 --- a/Delves/NightfallSanctum/Options/Sounds.lua +++ b/Delves/NightfallSanctum/Options/Sounds.lua @@ -13,3 +13,9 @@ BigWigs:AddSounds("Speaker Halven", { [443840] = "long", [443908] = "alarm", }) + +BigWigs:AddSounds("Cult Leaders", { + [434740] = "info", + [443482] = {"alert","info"}, + [458874] = "alarm", +}) diff --git a/Delves/NightfallSanctum/modules.xml b/Delves/NightfallSanctum/modules.xml index 2149d0de6..3373f23fb 100644 --- a/Delves/NightfallSanctum/modules.xml +++ b/Delves/NightfallSanctum/modules.xml @@ -3,6 +3,7 @@