Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Classic/Stratholme/TimmyTheCruel: Add boss module #1201

Merged
merged 1 commit into from
Nov 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions Classic/Stratholme/Options/Colors.lua
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ BigWigs:AddColors("The Unforgiven", {
})

BigWigs:AddColors("Timmy the Cruel", {
[8599] = "cyan",
[12021] = {"blue","red"},
[17470] = "purple",
})

BigWigs:AddColors("Commander Malor", {
Expand Down
3 changes: 3 additions & 0 deletions Classic/Stratholme/Options/Sounds.lua
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ BigWigs:AddSounds("The Unforgiven", {
})

BigWigs:AddSounds("Timmy the Cruel", {
[8599] = "long",
[12021] = "alarm",
[17470] = "alert",
})

BigWigs:AddSounds("Commander Malor", {
Expand Down
54 changes: 48 additions & 6 deletions Classic/Stratholme/TimmyTheCruel.lua
Original file line number Diff line number Diff line change
Expand Up @@ -6,33 +6,75 @@ local mod, CL = BigWigs:NewBoss("Timmy the Cruel", 329, 445)
if not mod then return end
mod:RegisterEnableMob(10808) -- Timmy the Cruel
mod:SetEncounterID(474)
--mod:SetRespawnTime(0)
--mod:SetRespawnTime(0) resets, doesn't respawn
mod:SetStage(1)

--------------------------------------------------------------------------------
-- Initialization
--

function mod:GetOptions()
return {

17470, -- Ravenous Claw
8599, -- Enrage
12021, -- Fixate
}
end

function mod:OnBossEnable()
self:Log("SPELL_CAST_SUCCESS", "RavenousClaw", 17470) -- no SPELL_CAST_START
self:Log("SPELL_CAST_SUCCESS", "Enrage", 8599)
if self:Retail() then
self:RegisterEvent("ENCOUNTER_START") -- XXX no boss frames
self:Log("SPELL_CAST_SUCCESS", "Fixate", 12021)
end
if self:Heroic() then -- no encounter events in Timewalking
self:RegisterEvent("INSTANCE_ENCOUNTER_ENGAGE_UNIT", "CheckBossStatus")
end
if self:Heroic() or self:Classic() then -- no encounter events in Timewalking, ENCOUNTER_END missing in Classic
self:Death("Win", 10808)
end
end

function mod:OnEngage()
self:SetStage(1)
end

--------------------------------------------------------------------------------
-- Classic Initialization
--

if mod:Classic() then
function mod:GetOptions()
return {
17470, -- Ravenous Claw
8599, -- Enrage
}
end
end

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

function mod:ENCOUNTER_START(_, id) -- XXX no boss frames
if id == self.engageId then
self:Engage()
function mod:RavenousClaw(args)
self:Message(args.spellId, "purple")
self:CDBar(args.spellId, 5.5)
self:PlaySound(args.spellId, "alert")
end

function mod:Enrage(args)
if self:MobId(args.sourceGUID) == 10808 then -- Timmy the Cruel
self:SetStage(2)
self:Message(args.spellId, "cyan", CL.percent:format(50, args.spellName))
self:CDBar(17470, 2.0) -- Ravenous Claw
self:PlaySound(args.spellId, "long")
end
end

function mod:Fixate(args)
self:TargetMessage(args.spellId, "red", args.destName)
self:CDBar(args.spellId, 21.8)
if self:Me(args.destGUID) then
self:PlaySound(args.spellId, "alarm")
end
end