Skip to content

Commit 2584453

Browse files
committed
More fixes for Midnight
1 parent 1f0b1a4 commit 2584453

File tree

1 file changed

+54
-2
lines changed

1 file changed

+54
-2
lines changed

Transcriptor.lua

Lines changed: 54 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1150,7 +1150,7 @@ do
11501150
end
11511151

11521152
function sh.UNIT_TARGET(unit)
1153-
if safeUnit(unit) then
1153+
if not issecretvalue(unit) and safeUnit(unit) then
11541154
return format("%s#%s#Target: %s#TargetOfTarget: %s", unit, tostring(TSUnitName(unit)), tostring(TSUnitName(unit.."target")), tostring(TSUnitName(unit.."targettarget")))
11551155
end
11561156
end
@@ -1309,10 +1309,59 @@ function sh.CHAT_MSG_RAID_BOSS_EMOTE(msg, npcName, ...)
13091309
return strjoin("#", msg, npcName, tostringall(...))
13101310
end
13111311

1312+
function sh.CHAT_MSG_RAID_BOSS_WHISPER(msg, npcName, ...)
1313+
if issecretvalue(msg) then return "SECRET" end
1314+
return strjoin("#", msg, npcName, tostringall(...))
1315+
end
1316+
1317+
function sh.CHAT_MSG_MONSTER_YELL(msg, ...)
1318+
if issecretvalue(msg) then return "SECRET" end
1319+
return strjoin("#", msg, tostringall(...))
1320+
end
1321+
sh.CHAT_MSG_MONSTER_EMOTE = sh.CHAT_MSG_MONSTER_YELL
1322+
sh.CHAT_MSG_MONSTER_SAY = sh.CHAT_MSG_MONSTER_YELL
1323+
sh.CHAT_MSG_MONSTER_WHISPER = sh.CHAT_MSG_MONSTER_YELL
1324+
13121325
function sh.ENCOUNTER_TIMELINE_EVENT_ADDED(eventInfo)
13131326
return strjoin("#", eventInfo.id, eventInfo.source, eventInfo.duration, eventInfo.maxQueueDuration)
13141327
end
13151328

1329+
function sh.ENCOUNTER_TIMELINE_EVENT_REMOVED(eventID)
1330+
return strjoin("#", eventID)
1331+
end
1332+
sh.ENCOUNTER_TIMELINE_EVENT_STATE_CHANGED = sh.ENCOUNTER_TIMELINE_EVENT_REMOVED
1333+
1334+
do
1335+
local entriesInTable = {
1336+
"text",
1337+
"casterGUID",
1338+
"casterName",
1339+
"targetGUID",
1340+
"targetName",
1341+
"iconFileID",
1342+
"tooltipSpellID",
1343+
"isDeadly",
1344+
"duration",
1345+
"severity",
1346+
"shouldPlaySound",
1347+
"shouldShowChatMessage",
1348+
"shouldShowWarning",
1349+
}
1350+
function sh.ENCOUNTER_WARNING(encounterWarningInfo)
1351+
local msgTable = {}
1352+
for i = 1, #entriesInTable do
1353+
local entry = entriesInTable[i]
1354+
local value = encounterWarningInfo[entry]
1355+
if not issecretvalue(value) then
1356+
msgTable[#msgTable+1] = entry
1357+
msgTable[#msgTable+1] = tostring(value)
1358+
end
1359+
end
1360+
local msg = tconcat(msgTable, "#")
1361+
return msg
1362+
end
1363+
end
1364+
13161365
do
13171366
local GetAuraDataByIndex = C_UnitAuras.GetAuraDataByIndex
13181367
function sh.UNIT_AURA(unit, updateInfo)
@@ -1378,7 +1427,7 @@ end
13781427

13791428
function sh.NAME_PLATE_UNIT_ADDED(unit)
13801429
local guid = UnitGUID(unit)
1381-
if not collectNameplates[guid] then
1430+
if not issecretvalue(guid) and not collectNameplates[guid] then
13821431
collectNameplates[guid] = true
13831432
local name = TSUnitName(unit)
13841433
return strjoin("#", name, guid)
@@ -1403,6 +1452,9 @@ local wowEvents = {
14031452
-- Raids
14041453
"CHAT_MSG_ADDON",
14051454
"ENCOUNTER_TIMELINE_EVENT_ADDED",
1455+
"ENCOUNTER_TIMELINE_EVENT_REMOVED",
1456+
"ENCOUNTER_TIMELINE_EVENT_STATE_CHANGED",
1457+
"ENCOUNTER_WARNING",
14061458
"CHAT_MSG_RAID_WARNING",
14071459
"PLAYER_REGEN_DISABLED",
14081460
"PLAYER_REGEN_ENABLED",

0 commit comments

Comments
 (0)