Skip to content

Commit

Permalink
Adds tracking for runner snatches (#16314)
Browse files Browse the repository at this point in the history
Co-authored-by: Tempolx <[email protected]>
  • Loading branch information
Mantlecrawler and Mantlecrawler authored Jul 14, 2024
1 parent 720e27b commit 3948af7
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 0 deletions.
2 changes: 2 additions & 0 deletions code/datums/gamemodes/_game_mode.dm
Original file line number Diff line number Diff line change
Expand Up @@ -481,6 +481,8 @@ GLOBAL_LIST_INIT(bioscan_locations, list(
parts += "[GLOB.round_statistics.points_from_mining] requisitions points gained from mining."
if(GLOB.round_statistics.points_from_research)
parts += "[GLOB.round_statistics.points_from_research] requisitions points gained from research."
if(GLOB.round_statistics.runner_items_stolen)
parts += "[GLOB.round_statistics.runner_items_stolen] items stolen by runners."

if(GLOB.round_statistics.sandevistan_uses)
var/sandevistan_text = "[GLOB.round_statistics.sandevistan_uses] number of times someone was boosted by a sandevistan"
Expand Down
3 changes: 3 additions & 0 deletions code/datums/personal_statistics.dm
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ GLOBAL_LIST_EMPTY(personal_statistics_list)
var/recycle_points_denied = 0
var/huggers_created = 0
var/impregnations = 0
var/items_snatched = 0

//Close air support
var/cas_cannon_shots = 0
Expand Down Expand Up @@ -229,6 +230,8 @@ GLOBAL_LIST_EMPTY(personal_statistics_list)
support_stats += "Performed [miner_repairs_performed] miner repair\s."
if(apcs_repaired)
support_stats += "Repaired [apcs_repaired] APC\s."
if(items_snatched)
support_stats += "Snatched [items_snatched] items\s."

if(generator_sabotages_performed)
support_stats += "Sabotaged [generator_sabotages_performed] generator\s."
Expand Down
1 change: 1 addition & 0 deletions code/datums/round_statistics.dm
Original file line number Diff line number Diff line change
Expand Up @@ -101,3 +101,4 @@ GLOBAL_DATUM_INIT(round_statistics, /datum/round_statistics, new)
var/psy_shield_blasts = 0
var/sandevistan_uses = 0
var/sandevistan_gibs = 0
var/runner_items_stolen = 0
Original file line number Diff line number Diff line change
Expand Up @@ -349,6 +349,11 @@
owner_turned(null, null, owner.dir)
succeed_activate()
add_cooldown()
GLOB.round_statistics.runner_items_stolen++
SSblackbox.record_feedback("tally", "round_statistics", 1, "runner_items_stolen")
if(owner.client)
var/datum/personal_statistics/personal_statistics = GLOB.personal_statistics_list[owner.ckey]
personal_statistics.items_snatched++

///Signal handler to update the item overlay when the owner is changing dir
/datum/action/ability/activable/xeno/snatch/proc/owner_turned(datum/source, old_dir, new_dir)
Expand Down

0 comments on commit 3948af7

Please sign in to comment.