1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 |
---------------------------
-- Individual Log Record --
---------------------------
return object
end
self . unitId = unitId
self . unitName = unitName
end
self . damageTaken = self . damageTaken + hitValue
end
CHAT_ROUTER : AddSystemMessage ( zo_strformat ( SI_TARGET_DUMMY_DPS_RESULT_FORMAT , dps , ZO_FormatTimeAsDecimalWhenBelowThreshold ( timeSpentTakingDamage ) , self . unitName ) )
end
self . lastHitReceivedTimeS = nil
self . damageTaken = 0
end
return self . damageTaken
end
do
local MIN_TIME_S = 1
if self . startTimeS and self . lastHitReceivedTimeS then
end
return 0
end
end
if timeSpentTakingDamage > 0 then
return self . damageTaken / timeSpentTakingDamage
end
return 0
end
-------------------------------------
-- Target Dummy Log Manager Object --
-------------------------------------
return object
end
self . logObjects = { }
end
end
end
end
EVENT_MANAGER : AddFilterForEvent ( "TargetDummyLog" , EVENT_COMBAT_EVENT , REGISTER_FILTER_TARGET_COMBAT_UNIT_TYPE , COMBAT_UNIT_TYPE_TARGET_DUMMY )
end
function ZO_TargetDummyLog_Manager : HandleCombatEvent ( actionResult , isError , abilityName , abilityGraphic , abilityActionSlotType , sourceName , sourceType , targetName , targetType , hitValue , powerType , damageType , shouldLog , sourceUnitId , targetUnitId , abilityId )
local isFromMe = sourceType == COMBAT_UNIT_TYPE_PLAYER or sourceType == COMBAT_UNIT_TYPE_PLAYER_PET
local isDPSEvent = hitValue > 0 and powerType ~= POWERTYPE_INVALID
if isFromMe and isDPSEvent then
local logObject = self . logObjects [ targetUnitId ]
if not logObject then
self . logObjects [ targetUnitId ] = logObject
end
end
end
if self . inCombat ~= inCombat then
self . inCombat = inCombat
if not inCombat then
end
end
end
|