Credit kills by illusions of the victim instead of dropping them as suicides - #90
Open
geracosta wants to merge 1 commit into
Open
Credit kills by illusions of the victim instead of dropping them as suicides#90geracosta wants to merge 1 commit into
geracosta wants to merge 1 commit into
Conversation
…uicides The attacker==victim filter is meant for suicides, but an illusion of the victim (Dark Portrait, Disruption, Wall of Replica) carries the victim's unit name and got dropped too. A real suicide is never dealt by an illusion, and sourcename already resolves the kill to the illusion's owner. Verified on match 8754463676: Muerta's death at 2057s to Grimstroke's Dark Portrait illusion is restored to kills_log/killed_by, matching the scoreboard (39 radiant kills), with the standard test replay byte-identical to master.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
kills_logandkilled_bydrop any kill where the combat log attacker has the same unit name as the victim. That's meant for suicides (Techies), but it also swallows a real kill class: an illusion of the victim landing the killing blow — Grimstroke's Dark Portrait, Shadow Demon's Disruption, Wall of Replica. The attacking illusion carries the victim's unit name, so the filter can't tell it apart by name, butattackerillusioncan: a real suicide is never dealt by an illusion.Attribution comes out right on its own:
sourcenamealready resolves illusion damage to the owning hero (the same mechanism damage counting uses), so the recovered kill lands on the illusion's owner.Example (reported by a user on Discord): match 8754463676 has radiant score 39, but radiant
kills_logsums to 38. The missing one is Muerta's death at 2057s, dealt by a Dark Portrait illusion of herself — Grimstroke bought Aghs at 2012s, and his damage map includesmuerta_gunslinger/muerta_pierce_the_veil, which only that illusion can produce. The scoreboard credits Grimstroke with 5 kills; hiskills_loghas 4.Validation:
kills_log4→5 (adds{"time": 2057, "key": "npc_dota_hero_muerta"}), hiskilledmap muerta 1→2, Muerta'skilled_bygrimstroke 1→2 (herkilled_bynow sums to her 4 deaths), plus the corresponding teamfight entry. Radiantkills_logtotal becomes 39 = radiant score.Related: odota/core#1430 is the neighboring case (a tower lands the last hit while the game credits a nearby hero) — that one isn't recoverable from the combat log; this one is.