--PLAYER_DEAD COMBAT_LOG_EVENT_UNFILTERED
function(...)
	local se = select(3, ...)
	if se == "SPELL_DAMAGE" or se == "SPELL_PERIODIC_DAMAGE" then
		local caster = select(6, ...)
		local target = select(10, ...)
		local overkill = select(17, ...)
		if overkill > 0 and target == UnitName("player") then
			local id = #DED + 1
			local date = date()
			local localtime = date:match("%d%d%/%d%d%/%d%d%s(%d%d%p%d%d%p%d%d)")
			local year = date:match("%d%d%/%d%d/(%d%d)") + 2000 --01/07/(19) 14:36:42
			local month = date:match("(%d%d)") --(01)/07/19 14:36:42
			local day = date:match("%d%d%/(%d%d)") --01/(07)/19 14:36:42
			--Remove first place zeros
			if day:find("0") == 1 then
				day = day:gsub("0", "")
			end
			if month:find("0") == 1 then
				month = month:gsub("0", "")
			end
			local localdate = day .. "." .. month .. "." .. year
			local localzone = GetZoneText()
			DED[id] = 
			{
				["Date"] = localdate,
				["Time"] = localtime,
				["Zone"] = localzone,
				["Killer"] = caster,
				["Overkill"] = overkill
			}
		end
	end
	if se == "SWING_DAMAGE" then
		local caster = select(6, ...)
		local target = select(10, ...)
		local overkill = select(14, ...)
		if overkill > 0 and target == UnitName("player") then
			local id = #DED + 1
			local date = date()
			local localtime = date:match("%d%d%/%d%d%/%d%d%s(%d%d%p%d%d%p%d%d)")
			local year = date:match("%d%d%/%d%d/(%d%d)") + 2000 --01/07/(19) 14:36:42
			local month = date:match("(%d%d)") --(01)/07/19 14:36:42
			local day = date:match("%d%d%/(%d%d)") --01/(07)/19 14:36:42
			--Remove first place zeros
			if day:find("0") == 1 then
				day = day:gsub("0", "")
			end
			if month:find("0") == 1 then
				month = month:gsub("0", "")
			end
			local localdate = day .. "." .. month .. "." .. year
			local localzone = GetZoneText()
			DED[id] = 
			{
				["Date"] = localdate,
				["Time"] = localtime,
				["Zone"] = localzone,
				["Killer"] = caster,
				["Overkill"] = overkill
			}
		end
	end
end