-
Notifications
You must be signed in to change notification settings - Fork 79
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Cataclysm/ThroneTides/Nazjar: High Tide, Shock Blast, Geysers, Focuse…
…d Tempest, Trident Flurry
- Loading branch information
Showing
3 changed files
with
131 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,60 +1,158 @@ | ||
|
||
local isTenDotTwo = select(4, GetBuildInfo()) >= 100200 --- XXX delete when 10.2 is live everywhere | ||
-------------------------------------------------------------------------------- | ||
-- Module declaration | ||
-- Module Declaration | ||
-- | ||
|
||
local mod, CL = BigWigs:NewBoss("Lady Naz'jar", 643, 101) | ||
if not mod then return end | ||
mod:RegisterEnableMob(40586) | ||
mod.engageId = 1045 | ||
mod.respawnTime = 30 | ||
mod:SetEncounterID(1045) | ||
mod:SetRespawnTime(30) | ||
|
||
-------------------------------------------------------------------------------- | ||
-- Locals | ||
-- | ||
|
||
local nextSpoutWarning = 66 | ||
local highTideCount = 1 | ||
|
||
-------------------------------------------------------------------------------- | ||
-- Initialization | ||
-- | ||
|
||
function mod:GetOptions() | ||
return { | ||
75683, -- Waterspout | ||
-- Lady Naz'jar | ||
75683, -- High Tide | ||
{428054, "SAY"}, -- Shock Blast | ||
427771, -- Geysers | ||
{428374, "ME_ONLY_EMPHASIZE"}, -- Focused Tempest | ||
{428263, "OFF"}, -- Water Bolt | ||
-- Naz'jar Honor Guard | ||
428293, -- Trident Flurry | ||
}, { | ||
[75683] = self.displayName, | ||
[428293] = -2183, -- Naz'jar Honor Guard | ||
} | ||
end | ||
|
||
function mod:OnBossEnable() | ||
self:RegisterUnitEvent("UNIT_HEALTH", nil, "boss1") | ||
self:Log("SPELL_AURA_APPLIED", "Waterspout", 75683) | ||
self:Log("SPELL_AURA_REMOVED", "WaterspoutRemoved", 75683) | ||
-- Lady Naz'jar | ||
-- XXX remove this listener from the if block when 10.2 is live everywhere | ||
if isTenDotTwo then | ||
self:Log("SPELL_CAST_START", "HighTideStarting", 75683) | ||
end | ||
self:Log("SPELL_AURA_APPLIED", "HighTide", 75683) | ||
self:Log("SPELL_AURA_REMOVED", "HighTideOver", 75683) | ||
-- XXX remove these listeners from the if block when 10.2 is live everywhere | ||
if isTenDotTwo then | ||
self:Log("SPELL_CAST_START", "ShockBlast", 428054) | ||
self:Log("SPELL_CAST_START", "Geysers", 427771) | ||
self:Log("SPELL_CAST_START", "FocusedTempest", 428374) | ||
self:Log("SPELL_CAST_START", "WaterBolt", 428263) | ||
|
||
-- Naz'jar Honor Guard | ||
self:Log("SPELL_CAST_START", "TridentFlurry", 428293) | ||
self:Death("NazjarHonorGuardDeath", 40633) | ||
end | ||
end | ||
|
||
function mod:OnEngage() | ||
nextSpoutWarning = 66 | ||
highTideCount = 1 | ||
-- XXX remove these timers from the if block when 10.2 is live everywhere | ||
if isTenDotTwo then | ||
self:CDBar(428374, 7.4) -- Focused Tempest | ||
self:CDBar(427771, 16.1) -- Geysers | ||
self:CDBar(428054, 19.7) -- Shock Blast | ||
end | ||
end | ||
|
||
-- XXX delete this entire block below when 10.2 is live everywhere | ||
if not isTenDotTwo then | ||
function mod:GetOptions() | ||
return { | ||
75683, -- Waterspout | ||
} | ||
end | ||
end | ||
|
||
-------------------------------------------------------------------------------- | ||
-- Event Handlers | ||
-- | ||
|
||
function mod:Waterspout(args) | ||
self:Bar(args.spellId, 60) | ||
-- Lady Naz'jar | ||
|
||
function mod:HighTideStarting(args) | ||
self:StopBar(428374) -- Focused Tempest | ||
self:StopBar(427771) -- Geysers | ||
self:StopBar(428054) -- Shock Blast | ||
end | ||
|
||
function mod:HighTide(args) | ||
local percent = highTideCount == 1 and 60 or 30 | ||
self:Message(args.spellId, "cyan", CL.percent:format(percent, args.spellName)) | ||
self:PlaySound(args.spellId, "long") | ||
highTideCount = highTideCount + 1 | ||
end | ||
|
||
function mod:HighTideOver(args) | ||
self:Message(args.spellId, "cyan", CL.over:format(args.spellName)) | ||
self:PlaySound(args.spellId, "info") | ||
-- XXX remove these timers from the if block when 10.2 is live everywhere | ||
if isTenDotTwo then | ||
self:CDBar(428374, 2.4) -- Focused Tempest | ||
self:CDBar(428054, 24.3) -- Shock Blast | ||
self:CDBar(427771, 28.0) -- Geysers | ||
end | ||
end | ||
|
||
do | ||
local function printTarget(self, player, guid) | ||
if self:Me(guid) then | ||
self:Say(428054) -- Shock Blast | ||
end | ||
end | ||
|
||
function mod:ShockBlast(args) | ||
self:GetBossTarget(printTarget, 0.4, args.sourceGUID) | ||
self:Message(args.spellId, "purple") | ||
self:PlaySound(args.spellId, "alarm") | ||
self:CDBar(args.spellId, 26.7) | ||
end | ||
end | ||
|
||
function mod:WaterspoutRemoved(args) -- if all 3 adds die, she stops casting | ||
self:StopBar(args.spellId) | ||
function mod:Geysers(args) | ||
self:Message(args.spellId, "orange") | ||
self:PlaySound(args.spellId, "alarm") | ||
self:CDBar(args.spellId, 29.1) | ||
end | ||
|
||
function mod:UNIT_HEALTH(event, unit) | ||
local hp = self:GetHealth(unit) | ||
if hp < nextSpoutWarning then | ||
self:MessageOld(75683, "yellow", nil, CL.soon:format(self:SpellName(75683)), false) | ||
nextSpoutWarning = nextSpoutWarning - 30 | ||
if nextSpoutWarning < 36 then | ||
self:UnregisterUnitEvent(event, unit) | ||
do | ||
local function printTarget(self, player, guid) | ||
if self:Healer() or self:Me(guid) then | ||
self:TargetMessage(428374, "yellow", player) | ||
self:PlaySound(428374, "alert", nil, player) | ||
end | ||
end | ||
|
||
function mod:FocusedTempest(args) | ||
self:GetBossTarget(printTarget, 0.4, args.sourceGUID) | ||
self:CDBar(args.spellId, 14.5) | ||
end | ||
end | ||
|
||
function mod:WaterBolt(args) | ||
self:Message(args.spellId, "red", CL.casting:format(args.spellName)) | ||
self:PlaySound(args.spellId, "alert") | ||
end | ||
|
||
-- Naz'jar Honor Guard | ||
|
||
function mod:TridentFlurry(args) | ||
self:Message(args.spellId, "orange") | ||
self:PlaySound(args.spellId, "alarm") | ||
self:CDBar(args.spellId, 11.9) | ||
end | ||
|
||
function mod:NazjarHonorGuardDeath(args) | ||
self:StopBar(428293) -- Trident Flurry | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters