-
Notifications
You must be signed in to change notification settings - Fork 317
Description
Okay, I've decided to split this from #502 because this needs some parser work.
- Add counter-ward log into the match
- Make the table to show this stuff in the SPA
- Aggregate the counter-ward stat into the player's stat, avg CW/game avg CW(vs)/game
I've used manta to prototype my idea for the counter-warder detection and it seems to be working.
Basically, I'd credit the counter-ward to the player who last hit the ward, which to me seems reasonable.
The wards bounty is static to 100 gold and tracking the observer_left entity and correlating the time stamp with the combat log seems to be reliable to detect a counter ward.
Combat logs XP and Gold gains have reasons, and it seems wards kills are credited in the "0" category which makes it easy to track these down. We need to discard the two first runes as they also gives 100 gold, listed as reason 0, but gives no XP.
I'll try to implement a prototype in clarity soon.
Here is a dump of my output with the counter-wards being emphasized:
Match ID: https://www.opendota.com/matches/2629077031/vision
-- RUNES --
2016/09/11 21:36:38 [type:DOTA_COMBATLOG_GOLD target_name:5 value:100 timestamp:232.28732 location_x:-2283.5266 location_y:1639.9314 gold_reason:0 timestamp_raw:232.50002 ] %!s(uint32=0) combat log
2016/09/11 21:36:38 [type:DOTA_COMBATLOG_GOLD target_name:1 value:100 timestamp:232.48737 location_x:2802.9983 location_y:-2215.6968 gold_reason:0 timestamp_raw:232.70001 ] %!s(uint32=0) combat log
-- CW 1 --
2016/09/11 21:36:39 [type:DOTA_COMBATLOG_GOLD target_name:5 value:100 timestamp:669.59143 location_x:-6094.9893 location_y:3180.3325 gold_reason:0 timestamp_raw:669.9 ] %!s(uint32=0) combat log
2016/09/11 21:36:39 [type:DOTA_COMBATLOG_XP target_name:5 value:12 timestamp:669.59143 location_x:-6094.9893 location_y:3180.3325 timestamp_raw:669.9 xp_reason:0 ] %!s(uint32=0) combat log
2016/09/11 21:36:39 [type:DOTA_COMBATLOG_XP target_name:4 value:12 timestamp:669.59143 location_x:-6215.85 location_y:3350.9321 timestamp_raw:669.9 xp_reason:0 ] %!s(uint32=0) combat log
-- CW 2 --
2016/09/11 21:36:39 [type:DOTA_COMBATLOG_GOLD target_name:23 value:100 timestamp:816.2556 location_x:2277 location_y:-2584.3223 gold_reason:0 timestamp_raw:816.5667 ] %!s(uint32=0) combat log
2016/09/11 21:36:39 [type:DOTA_COMBATLOG_XP target_name:23 value:25 timestamp:816.2556 location_x:2277 location_y:-2584.3223 timestamp_raw:816.5667 xp_reason:0 ] %!s(uint32=0) combat log
-- CW 3 --
2016/09/11 21:36:39 [type:DOTA_COMBATLOG_GOLD target_name:23 value:100 timestamp:1174.7014 location_x:2459.7761 location_y:-3179.9407 gold_reason:0 timestamp_raw:1175.1001 ] %!s(uint32=0) combat log
2016/09/11 21:36:39 [type:DOTA_COMBATLOG_XP target_name:23 value:12 timestamp:1174.7014 location_x:2459.7761 location_y:-3179.9407 timestamp_raw:1175.1001 xp_reason:0 ] %!s(uint32=0) combat log
2016/09/11 21:36:39 [type:DOTA_COMBATLOG_XP target_name:34 value:12 timestamp:1174.7014 location_x:3672.975 location_y:-3477.933 timestamp_raw:1175.1001 xp_reason:0 ] %!s(uint32=0) combat log
-- CW 4 --
2016/09/11 21:36:39 [type:DOTA_COMBATLOG_GOLD target_name:26 value:100 timestamp:1276.4766 location_x:338.1693 location_y:2324.7913 gold_reason:0 timestamp_raw:1276.9 ] %!s(uint32=0) combat log
2016/09/11 21:36:39 [type:DOTA_COMBATLOG_XP target_name:26 value:12 timestamp:1276.4766 location_x:338.1693 location_y:2324.7913 timestamp_raw:1276.9 xp_reason:0 ] %!s(uint32=0) combat log
2016/09/11 21:36:39 [type:DOTA_COMBATLOG_XP target_name:23 value:12 timestamp:1276.4766 location_x:888.6625 location_y:2324.547 timestamp_raw:1276.9 xp_reason:0 ] %!s(uint32=0) combat log
-- This is noise, a siege creep killed passively with 4 players around --
2016/09/11 21:36:40 [type:DOTA_COMBATLOG_XP target_name:4 value:22 timestamp:1713.6031 location_x:-6128.4707 location_y:3945.2356 timestamp_raw:1714.1667 xp_reason:0 ] %!s(uint32=0) combat log
2016/09/11 21:36:40 [type:DOTA_COMBATLOG_XP target_name:1 value:22 timestamp:1713.6031 location_x:-6076.0537 location_y:3959.78 timestamp_raw:1714.1667 xp_reason:0 ] %!s(uint32=0) combat log
2016/09/11 21:36:40 [type:DOTA_COMBATLOG_XP target_name:8 value:22 timestamp:1713.6031 location_x:-6021.2217 location_y:3270.5662 timestamp_raw:1714.1667 xp_reason:0 ] %!s(uint32=0) combat log
2016/09/11 21:36:40 [type:DOTA_COMBATLOG_XP target_name:5 value:22 timestamp:1713.6031 location_x:-6148.2285 location_y:4301.7153 timestamp_raw:1714.1667 xp_reason:0 ] %!s(uint32=0) combat log
-- CW 5 --
2016/09/11 21:36:40 [type:DOTA_COMBATLOG_GOLD target_name:23 value:100 timestamp:1838.6726 location_x:-634.4636 location_y:4218.1206 gold_reason:0 timestamp_raw:1839.2334 ] %!s(uint32=0) combat log
2016/09/11 21:36:40 [type:DOTA_COMBATLOG_XP target_name:23 value:12 timestamp:1838.6726 location_x:-634.4636 location_y:4218.1206 timestamp_raw:1839.2334 xp_reason:0 ] %!s(uint32=0) combat log
2016/09/11 21:36:40 [type:DOTA_COMBATLOG_XP target_name:32 value:12 timestamp:1838.6726 location_x:-632.0982 location_y:4278.5786 timestamp_raw:1839.2334 xp_reason:0 ] %!s(uint32=0) combat log
-- This is noise, a siege creep killed passively with 4 players around --
2016/09/11 21:36:40 [type:DOTA_COMBATLOG_XP target_name:5 value:22 timestamp:2090.8674 location_x:3371.2307 location_y:5059.515 timestamp_raw:2091.3667 xp_reason:0 ] %!s(uint32=0) combat log
2016/09/11 21:36:40 [type:DOTA_COMBATLOG_XP target_name:6 value:22 timestamp:2090.8674 location_x:3321.6575 location_y:5240.7256 timestamp_raw:2091.3667 xp_reason:0 ] %!s(uint32=0) combat log
2016/09/11 21:36:40 [type:DOTA_COMBATLOG_XP target_name:8 value:22 timestamp:2090.8674 location_x:2139.9485 location_y:6142.9033 timestamp_raw:2091.3667 xp_reason:0 ] %!s(uint32=0) combat log
2016/09/11 21:36:40 [type:DOTA_COMBATLOG_XP target_name:4 value:22 timestamp:2090.8674 location_x:3548.6326 location_y:5151.606 timestamp_raw:2091.3667 xp_reason:0 ] %!s(uint32=0) combat log
2016/09/11 21:36:41 [type:DOTA_COMBATLOG_XP target_name:8 value:12 timestamp:2232.4497 location_x:3867.0032 location_y:3637.1309 timestamp_raw:2232.4668 xp_reason:0 ] %!s(uint32=0) combat log
2016/09/11 21:36:41 [type:DOTA_COMBATLOG_XP target_name:6 value:12 timestamp:2232.4497 location_x:3332.1968 location_y:3410.4011 timestamp_raw:2232.4668 xp_reason:0 ] %!s(uint32=0) combat log
2016/09/11 21:36:41 [type:DOTA_COMBATLOG_XP target_name:8 value:12 timestamp:2278.2056 location_x:2578.14 location_y:2279.69 timestamp_raw:2278.067 xp_reason:0 ] %!s(uint32=0) combat log
2016/09/11 21:36:41 [type:DOTA_COMBATLOG_XP target_name:1 value:12 timestamp:2278.2056 location_x:2974.2017 location_y:2090.23 timestamp_raw:2278.067 xp_reason:0 ] %!s(uint32=0) combat log
2016/09/11 21:36:41 Parse Complete!
I correctly identify all 5 counter-wards that happened and can credit them to the correct player.
Feel free to add your thoughts.