Parrot 2

Parrot 2

727k Downloads

Self-inflicted damage appears both in Incoming and Outgoing

0xjc opened this issue ยท 7 comments

commented

Damage where the source and destination GUID are both the player (e.g. Burning Rush or Eye of Corruption) are shown both in Incoming and Outgoing events. Most people would probably only want this shown under Incoming events. However, there is currently no way to achieve this effect.

In fact, even trying to set spell filters manually for each such spell doesn't fix this. Trying to do this would filter the self-damage spell from both the Incoming and Outgoing categories, even if only "Outgoing" is checked, because the event counts as both incoming & outgoing on the combat-log level.

commented

Quick and dirty way to accomplish this is by modifying Data/CombatEvents.lua

add function:

local function checkPlayerOutOther(srcGUID, _, srcFlags, dstGUID, _, dstFlags)
    return srcGUID == playerGUID and dstGUID ~= playerGUID
end

then events under Outgoing/Damage category can use checkPlayerOutOther instead of checkPlayerOut.

Or, perhaps better would be to duplicate all the outgoing damage types with a "self" variant like what already exists for outgoing heals:

  • Heals
  • Heals over time
  • Self heals
  • Self heals over time

So for outgoing damage we would have:

  • Melee damage
  • Reactive skills
  • Siege damage
  • Skill damage
  • Skill DoTs
  • Self melee damage
  • Self reactive skills
  • Self siege damage
  • Self skill damage
  • Self skill DoTs
commented

I don't think it really needs to be broken up, but but another category for "Self damage" would be good

commented

Agreed, that would avoid the clutter.

I've also realized this also applies to outgoing misses, particularly absorbs (e.g. avoid seeing absorbed Eye of Corruption damage in outgoing as well).

commented

(1) Alpha build mostly worked but "self damage absorbs" category wasn't working properly (it got filtered into generic "self damage miss"). I believe this is because

local function checkPlayerSelfIncAbsorb(srcGUID, _, _, dstGUID, _, _, missType)

has the arg count for a melee damage event. For spell damage it should be

local function checkPlayerSelfIncAbsorb(srcGUID, _, _, dstGUID, _, _, _, _, _, missType)

Similarly for outgoing.

(2) The latest commit 124da62 seems to be a regression. It reintroduces the original issue by letting outgoing self-damage count as generic "outgoing damage" again, so it can't be filtered by disabling "outgoing self damage" category.

(3) Finally as a minor sidenote,

local function checkPlayerSelfInc(srcGUID, _, _, dstGUID)
    return dstGUID == playerGUID and srcGUID == dstGUID
end
local function checkPlayerSelfOut(srcGUID, _, _, dstGUID)
    return srcGUID == playerGUID and srcGUID == dstGUID
end

these are functionally equivalent so only one of them is needed (similarly for checkPlayerSelf[Inc/Out]Absorb, checkPlayerSelf[Inc/Out]Miss).

commented

yep, definitely c/p'd the missType param from SWING_DAMAGE and missed replacing the outgoing check functions in the last commit.

Thanks for looking over it, should be sorted in b850fa4 now

commented

I think I covered everything, try out the alpha build and let me know how it works

commented

Everything seems to be working fine now. Thanks for the quick fixes.