Skip to content
Open
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
4 changes: 3 additions & 1 deletion Fights.lua
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@ function Fights:MoveFights()
for i = math.min(#Recount.db2.FoughtWho, Recount.db.profile.MaxFights - 1), 1, -1 do
Recount.db2.FoughtWho[i + 1] = Recount.db2.FoughtWho[i]
end
Recount.db2.FoughtWho[1] = Recount.FightingWho.." "..Recount.InCombatF.."-"..date("%H:%M:%S")
local fwLabel = ""
pcall(function() fwLabel = Recount.FightingWho end)
Recount.db2.FoughtWho[1] = fwLabel.." "..Recount.InCombatF.."-"..date("%H:%M:%S")
end

for k, v in pairs(Recount.db2.combatants) do
Expand Down
3 changes: 2 additions & 1 deletion Recount.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1634,7 +1634,8 @@ function Recount:LeaveCombat(Time)
end
-- Did we actually fight someone?
Recount.InCombat = false
if (Recount.FightingWho == "") then
local fwOk, fwEmpty = pcall(function() return Recount.FightingWho == "" end)
if fwOk and fwEmpty then
return
end
-- Elsia: Only sync for actual fights
Expand Down
9 changes: 6 additions & 3 deletions Tracker.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1824,9 +1824,12 @@ function Recount:BossFightWhoFromFlags(srcFlags, dstFlags, victim, victimGUID)
if Recount.IsBoss(victimGUID) then
Recount.FightingWho = victim
Recount.FightingLevel = -1
elseif Recount.FightingWho == "" then
Recount.FightingWho = victim
Recount.FightingLevel = 1
else
local fwOk, fwEmpty = pcall(function() return Recount.FightingWho == "" end)
if fwOk and fwEmpty then
Recount.FightingWho = victim
Recount.FightingLevel = 1
end
end
end
end
Expand Down