Author: Omega
Date: Sat Jul 17 21:04:06 CEST 2010
Revision: 4349
Log:

#Ruby/Halion: Added whisper (OFF by default) option for debuffs.
#Ruby/Halion: Experimental aggro detection for phase switches to improve accuracy of first conbustion/consumption timer on a phase change. (not yet tested, requires at minimum tanks running this revision or later to sync their pulls)

Updated
trunk/DBM-ChamberOfAspects/Ruby/Halion.lua
Updated
trunk/DBM-ChamberOfAspects/localization.en.lua
Updated
trunk/DBM-Icecrown/ThePlagueworks/Rotface.lua

trunk/DBM-ChamberOfAspects/Ruby/Halion.lua
Action: modified
Old revision: 4348
Old date: 2010-07-17 10:17:23 UTC

@@ -14,6 +14,9 @@
"SPELL_AURA_APPLIED",
"SPELL_AURA_REMOVED",
"SPELL_DAMAGE",
+ "SPELL_MISSED",
+ "SWING_DAMAGE",
+ "SWING_MISSED",
"CHAT_MSG_MONSTER_YELL",
"CHAT_MSG_RAID_BOSS_EMOTE",
"UNIT_HEALTH"
@@ -51,10 +54,15 @@

mod:AddBoolOption("YellOnConsumption", true, "announce")
mod:AddBoolOption("AnnounceAlternatePhase", true, "announce")
+mod:AddBoolOption("WhisperOnConsumption", false, "announce")
mod:AddBoolOption("SetIconOnConsumption", true)

local warned_preP2 = false
local warned_preP3 = false
+local phase2Started = 0
+local physicalAggro = false
+local twilightAggro = false
+local lastflame = 0

function mod:OnCombatStart(delay)--These may still need retuning too, log i had didn't have pull time though.
berserkTimer:Start(-delay)
@@ -63,6 +71,10 @@
timerFieryBreathCD:Start(10-delay)
warned_preP2 = false
warned_preP3 = false
+ phase2Started = 0
+ physicalAggro = true
+ twilightAggro = false
+ lastflame = 0
end

function mod:SPELL_CAST_START(args)
@@ -105,7 +117,10 @@
if args:IsSpellID(74792) then
if not self.Options.AnnounceAlternatePhase then
warningShadowConsumption:Show(args.destName)
+ if DBM:GetRaidRank() >= 1 and self.Options.WhisperOnConsumption then
+ SendChatMessage(L.WhisperConsumption, "WHISPER", "COMMON", args.destName)
end
+ end
if mod:LatencyCheck() then
self:SendSync("ShadowTarget", args.destName)
end
@@ -122,7 +137,10 @@
elseif args:IsSpellID(74562) then
if not self.Options.AnnounceAlternatePhase then
warningFieryConsumption:Show(args.destName)
+ if DBM:GetRaidRank() >= 1 and self.Options.WhisperOnConsumption then
+ SendChatMessage(L.WhisperCombustion, "WHISPER", "COMMON", args.destName)
end
+ end
if mod:LatencyCheck() then
self:SendSync("FieryTarget", args.destName)
end
@@ -151,16 +169,59 @@
end
end

-do
- local lastflame = 0
+--Begin Phase aggro detection
function mod:SPELL_DAMAGE(args)
if (args:IsSpellID(75952, 75951, 75950, 75949) or args:IsSpellID(75948, 75947)) and args:IsPlayer() and time() - lastflame > 2 then
- specWarnMeteorStrike:Show()
+ specWarnMeteorStrike:Show() --Standing in meteor, not part of aggro detection.
lastflame = time()
+ elseif args:GetDestCreatureID() == 39863 then
+ if not physicalAggro and GetTime() - phase2Started > 10 then --We don't have phase 3 aggro on him yet.
+ self:SendSync("PhysicalAggro")--We do now.
end
+ elseif args:GetDestCreatureID() == 40141 then
+ if not twilightAggro then --We don't have aggro on him yet.
+ self:SendSync("twilightAggro")--We do now.
end
end
+end

+function mod:SPELL_MISSED(args)
+ if args:GetDestCreatureID() == 39863 then
+ if not physicalAggro and GetTime() - phase2Started > 10 then --We don't have phase 3 aggro on him yet.
+ self:SendSync("PhysicalAggro")--We do now.
+ end
+ elseif args:GetDestCreatureID() == 40141 then
+ if not twilightAggro then --We don't have aggro on him yet.
+ self:SendSync("twilightAggro")--We do now.
+ end
+ end
+end
+
+function mod:SWING_DAMAGE(args)
+ if args:GetDestCreatureID() == 39863 then
+ if not physicalAggro and GetTime() - phase2Started > 10 then --We don't have phase 3 aggro on him yet.
+ self:SendSync("PhysicalAggro")--We do now.
+ end
+ elseif args:GetDestCreatureID() == 40141 then
+ if not twilightAggro then --We don't have aggro on him yet.
+ self:SendSync("twilightAggro")--We do now.
+ end
+ end
+end
+
+function mod:SWING_MISSED(args)
+ if args:GetDestCreatureID() == 39863 then
+ if not physicalAggro and GetTime() - phase2Started > 10 then --We don't have phase 3 aggro on him yet.
+ self:SendSync("PhysicalAggro")--We do now.
+ end
+ elseif args:GetDestCreatureID() == 40141 then
+ if not twilightAggro then --We don't have aggro on him yet.
+ self:SendSync("twilightAggro")--We do now.
+ end
+ end
+end
+--End Phase aggro detection
+
function mod:UNIT_HEALTH(uId)
if not warned_preP2 and self:GetUnitCreatureId(uId) == 39863 and UnitHealth(uId) / UnitHealthMax(uId) <= 0.79 then
warned_preP2 = true
@@ -176,18 +237,18 @@
timerFieryBreathCD:Cancel()
timerMeteorCD:Cancel()
timerFieryConsumptionCD:Cancel()
--- timerMeteorCast:Cancel()--This one i'm not sure if it cancels or not.
warnPhase2:Show()
timerShadowBreathCD:Start(25)
--- timerShadowConsumptionCD:Start(20)--Don't know it yet need more logs, it's not showing consistency. 20-25 on normal.
- if mod:IsDifficulty("heroic10") or mod:IsDifficulty("heroic25") then
+ if mod:IsDifficulty("heroic10") or mod:IsDifficulty("heroic25") then --These i'm not sure if they start regardless of drake aggro, or if it should be moved too.
timerTwilightCutterCD:Start(30)
else
timerTwilightCutterCD:Start(35)
end
+ physicalAggro = false
+ phase2Started = GetTime()
elseif msg:find(L.Phase3) then
warnPhase3:Show()
- timerMeteorCD:Start(30)
+ timerMeteorCD:Start(30) --These i'm not sure if they start regardless of drake aggro, or if it should be moved too.
elseif msg:find(L.MeteorCast) then--There is no CLEU cast trigger for meteor, only yell
if not self.Options.AnnounceAlternatePhase then
warningMeteor:Show()
@@ -233,11 +294,17 @@
elseif msg == "ShadowTarget" then
if self.Options.AnnounceAlternatePhase then
warningShadowConsumption:Show(target)
+ if DBM:GetRaidRank() >= 1 and self.Options.WhisperOnConsumption then
+ SendChatMessage(L.WhisperConsumption, "WHISPER", "COMMON", target)
end
+ end
elseif msg == "FieryTarget" then
if self.Options.AnnounceAlternatePhase then
warningFieryConsumption:Show(target)
+ if DBM:GetRaidRank() >= 1 and self.Options.WhisperOnConsumption then
+ SendChatMessage(L.WhisperCombustion, "WHISPER", "COMMON", target)
end
+ end
elseif msg == "ShadowCD" then
if self.Options.AnnounceAlternatePhase then
if mod:IsDifficulty("heroic10") or mod:IsDifficulty("heroic25") then
@@ -254,5 +321,9 @@
timerFieryConsumptionCD:Start()
end
end
+ elseif msg == "PhysicalAggro" then
+ timerFieryConsumptionCD:Start(15)--Timer doesn't start again until aggroed again in phase 3. Timer value itself may need adjusting now that it's starting in right place
+ elseif msg == "twilightAggro" then
+ timerShadowConsumptionCD:Start(15)--Timer doesn't start until actual twilight form is aggroed. Timer value itself may need adjusting now that it's starting in right place
end
end


trunk/DBM-ChamberOfAspects/localization.en.lua
Action: modified
Old revision: 4348
Old date: 2010-07-17 10:17:23 UTC

@@ -177,7 +177,8 @@
AnnounceAlternatePhase = "Show warnings/timers for phase you aren't in as well",
SoundOnConsumption = "Play sound on $spell:74562 or $spell:74792",--We use localized text for these functions
SetIconOnConsumption = "Set icons on $spell:74562 or $spell:74792 targets",--So we can use single functions for both versions of spell.
- YellOnConsumption = "Yell on $spell:74562 or $spell:74792"
+ YellOnConsumption = "Yell on $spell:74562 or $spell:74792",
+ WhisperOnConsumption = "Send whisper to $spell:74562 or $spell:74792 targets"
})

L:SetMiscLocalization({
@@ -186,6 +187,8 @@
Phase3 = "I am the light and the darkness! Cower, mortals, before the herald of Deathwing!",
twilightcutter = "The orbiting spheres pulse with dark energy!",
YellCombustion = "Combustion on me!",
+ WhisperCombustion = "Combustion on you! Run to the wall!",
YellConsumption = "Consumption on me!",
+ WhisperConsumption = "Consumption on you! Run to the wall!",
Kill = "Relish this victory, mortals, for it will be your last. This world will burn with the master's return!"
})
\ No newline at end of file


trunk/DBM-Icecrown/ThePlagueworks/Rotface.lua
Action: modified
Old revision: 4348
Old date: 2010-07-17 10:17:23 UTC

@@ -159,7 +159,7 @@
function mod:SPELL_DAMAGE(args)
if args:IsSpellID(69761, 71212, 73026, 73027) and args:IsPlayer() then
specWarnRadiatingOoze:Show()
- elseif args:GetDestCreatureID() == 36899 and args:IsSrcTypePlayer() == UnitName("player") then
+ elseif args:GetDestCreatureID() == 36899 and args:IsSrcTypePlayer() then
if isKiter then --Tank/Hunter attacking big ooze
self:SendSync("OozeKiter", UnitName("player"))
end
@@ -169,7 +169,7 @@
function mod:SWING_DAMAGE(args)
if args:IsPlayer() and args:GetSrcCreatureID() == 36897 then --Little ooze hitting you
specWarnLittleOoze:Show()
- elseif args:GetDestCreatureID() == 36899 and args:IsSrcTypePlayer() == UnitName("player") then
+ elseif args:GetDestCreatureID() == 36899 and args:IsSrcTypePlayer() then
if isKiter then --Tank/Hunter attacking big ooze
self:SendSync("OozeKiter", UnitName("player"))
end