Skip to content

Commit

Permalink
Classic/KarazhanCrypts/Goblins: Add boss module (#1262)
Browse files Browse the repository at this point in the history
  • Loading branch information
ntowle authored Feb 8, 2025
1 parent 634340c commit 86122d7
Show file tree
Hide file tree
Showing 3 changed files with 84 additions and 0 deletions.
78 changes: 78 additions & 0 deletions Classic/KarazhanCrypts/Goblins.lua
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,93 @@ end

function mod:GetOptions()
return {
-- Geenkle
{16170, "DISPEL"}, -- Bloodlust
-- Jank
{744, "DISPEL"}, -- Poison
-- Gold Rustboot
27758, -- War Stomp
}, {
[16170] = L.geenkle,
[744] = L.jank,
[27758] = L.gold_rustboot,
}
end

function mod:OnBossEnable()
-- Geenkle
self:Log("SPELL_CAST_SUCCESS", "Bloodlust", 16170)
self:Log("SPELL_AURA_APPLIED", "BloodlustApplied", 16170)
self:Death("GeenkleDeath", 238416)

-- Jank
self:Log("SPELL_CAST_SUCCESS", "Poison", 744)
self:Log("SPELL_AURA_APPLIED", "PoisonApplied", 744)
self:Death("JankDeath", 238418)

-- Gold Rustboot
self:Log("SPELL_CAST_SUCCESS", "WarStomp", 27758)
self:Death("GoldRustbootDeath", 238419)
end

function mod:OnEngage()
self:CDBar(744, 7.0) -- Poison
self:CDBar(27758, 8.2) -- War Stomp
self:CDBar(16170, 11.2) -- Bloodlust
end

--------------------------------------------------------------------------------
-- Event Handlers
--

-- Geenkle

function mod:Bloodlust(args)
self:CDBar(args.spellId, 13.3)
end

function mod:BloodlustApplied(args)
if self:Me(args.destGUID) or (self:Dispeller("magic", true, args.spellId) and not self:Player(args.destFlags)) then
self:Message(args.spellId, "red", CL.on:format(args.spellName, args.destName))
self:PlaySound(args.spellId, "info")
end
end

function mod:GeenkleDeath()
self:StopBar(16170) -- Bloodlust
end

-- Jank

function mod:Poison(args)
-- also cast by trash
if self:MobId(args.sourceGUID) == 238418 then -- Jank
self:CDBar(args.spellId, 32.0)
end
end

function mod:PoisonApplied(args)
-- also cast by trash
if self:MobId(args.sourceGUID) == 238418 then -- Jank
if self:Me(args.destGUID) or (self:Dispeller("poison", nil, args.spellId) and self:Player(args.destFlags)) then
self:TargetMessage(args.spellId, "red", args.destName)
self:PlaySound(args.spellId, "alert", nil, args.destName)
end
end
end

function mod:JankDeath()
self:StopBar(744) -- Poison
end

-- Gold Rustboot

function mod:WarStomp(args)
self:Message(args.spellId, "yellow")
self:CDBar(args.spellId, 11.3)
self:PlaySound(args.spellId, "alert")
end

function mod:GoldRustbootDeath()
self:StopBar(27758) -- War Stomp
end
3 changes: 3 additions & 0 deletions Classic/KarazhanCrypts/Options/Colors.lua
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,9 @@ BigWigs:AddColors("Hans and Greta", {
})

BigWigs:AddColors("Goblins", {
[744] = {"blue","red"},
[16170] = "red",
[27758] = "yellow",
})

BigWigs:AddColors("Harbinger of Sin", {
Expand Down
3 changes: 3 additions & 0 deletions Classic/KarazhanCrypts/Options/Sounds.lua
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,9 @@ BigWigs:AddSounds("Hans and Greta", {
})

BigWigs:AddSounds("Goblins", {
[744] = "alert",
[16170] = "info",
[27758] = "alert",
})

BigWigs:AddSounds("Harbinger of Sin", {
Expand Down

0 comments on commit 86122d7

Please sign in to comment.