Skip to content

Commit

Permalink
SpecialEvents: Add support for Mistress Sassz'ine
Browse files Browse the repository at this point in the history
  • Loading branch information
funkydude committed Aug 13, 2017
1 parent e765c84 commit 98d56eb
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 2 deletions.
24 changes: 23 additions & 1 deletion SpecialEvents.lua
Original file line number Diff line number Diff line change
@@ -1,7 +1,29 @@
local n, tbl = ...
local tbl
do
local _
_, tbl = ...
end

tbl.specialEvents = {
["UNIT_SPELLCAST_SUCCEEDED"] = {
--[[ Tomb of Sargeras ]]--
[239423] = { -- Dread Shark
[115767] = function() -- Mistress Sassz'ine
tbl.data[1] = (tbl.data[1] or 1) + 1

local stage = tbl.data[1]
local _, _, diff = GetInstanceInfo()
if diff == 16 then -- Mythic
if stage == 3 then
return "Stage 2"
elseif stage == 5 then
return "Stage 3"
end
else
return "Stage ".. stage
end
end,
},
[235268] = { -- Lunar Ghost
[118523] = "Stage 2", -- Huntress Kasparian (Sisters of the Moon)
[118374] = "Stage 3", -- Captain Yathae Moonstrike (Sisters of the Moon)
Expand Down
10 changes: 9 additions & 1 deletion Transcriptor.lua
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,13 @@ end
local playerSpellBlacklist
local badSourcelessPlayerSpellList
local specialEvents
local data = {}

do
local n, tbl = ...
playerSpellBlacklist = tbl.blacklist
specialEvents = tbl.specialEvents
tbl.data = data
end

local logName = nil
Expand All @@ -37,7 +39,7 @@ local format, strjoin = string.format, string.join
local tostring, tostringall = tostring, tostringall
local type, select, next = type, select, next
local date = date
local debugprofilestop = debugprofilestop
local debugprofilestop, wipe = debugprofilestop, wipe
local print = print

local C_Scenario = C_Scenario
Expand Down Expand Up @@ -73,6 +75,10 @@ local function MobId(guid)
end

local function InsertSpecialEvent(name)
if type(name) == "function" then
name = name()
end
if not name then return end
if compareSuccess then
for id,tbl in next, compareSuccess do
for npcId, list in next, tbl do
Expand Down Expand Up @@ -864,6 +870,7 @@ end

function sh.ENCOUNTER_START(...)
compareStartTime = debugprofilestop()
wipe(data)
return strjoin("#", "ENCOUNTER_START", ...)
end

Expand Down Expand Up @@ -1149,6 +1156,7 @@ do
ldb.icon = "Interface\\AddOns\\Transcriptor\\icon_on"
previousWorldState = nil
shouldLogFlags = TranscriptIgnore.logFlags and true or false
wipe(data)

compareStartTime = debugprofilestop()
logStartTime = compareStartTime / 1000
Expand Down

0 comments on commit 98d56eb

Please sign in to comment.