From aab2c4cd3c6ec4f72ce35ed9175b758262ca6dfb Mon Sep 17 00:00:00 2001 From: Putnam Date: Thu, 7 Nov 2019 20:34:02 -0800 Subject: [PATCH] Added logging to wizard/traitor extra threat spending. --- code/modules/antagonists/traitor/datum_traitor.dm | 8 ++++++-- .../antagonists/wizard/equipment/spellbook.dm | 12 +++++++++--- 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/code/modules/antagonists/traitor/datum_traitor.dm b/code/modules/antagonists/traitor/datum_traitor.dm index 4b5cb94ad9..55f9fe483b 100644 --- a/code/modules/antagonists/traitor/datum_traitor.dm +++ b/code/modules/antagonists/traitor/datum_traitor.dm @@ -104,7 +104,9 @@ hijack_objective.owner = owner add_objective(hijack_objective) if(is_dynamic) - mode.spend_threat(CONFIG_GET(number/dynamic_hijack_cost)) + var/threat_spent = CONFIG_GET(number/dynamic_hijack_cost) + mode.spend_threat(threat_spent) + mode.threat_log += "[worldtime2text()]: Traitor spent [threat_spent] on hijack." return @@ -119,7 +121,9 @@ martyr_objective.owner = owner add_objective(martyr_objective) if(is_dynamic) - mode.spend_threat(CONFIG_GET(number/dynamic_glorious_death_cost)) + var/threat_spent = CONFIG_GET(number/dynamic_hijack_cost) + mode.spend_threat(threat_spent) + mode.threat_log += "[worldtime2text()]: Traitor spent [threat_spent] on glorious death." return else diff --git a/code/modules/antagonists/wizard/equipment/spellbook.dm b/code/modules/antagonists/wizard/equipment/spellbook.dm index ab37997e50..71b92feec6 100644 --- a/code/modules/antagonists/wizard/equipment/spellbook.dm +++ b/code/modules/antagonists/wizard/equipment/spellbook.dm @@ -496,7 +496,9 @@ to_chat(user, "You have cast summon guns!") if(istype(SSticker.mode,/datum/game_mode/dynamic)) var/datum/game_mode/dynamic/mode = SSticker.mode - mode.spend_threat(CONFIG_GET(number/dynamic_summon_guns_cost)) + var/threat_spent = CONFIG_GET(number/dynamic_summon_guns_cost) + mode.spend_threat(threat_spent) + mode.threat_log += "[worldtime2text()]: Wizard spent [threat_spent] on summon guns." return 1 /datum/spellbook_entry/summon/magic @@ -520,7 +522,9 @@ to_chat(user, "You have cast summon magic!") if(istype(SSticker.mode,/datum/game_mode/dynamic)) var/datum/game_mode/dynamic/mode = SSticker.mode - mode.spend_threat(CONFIG_GET(number/dynamic_summon_magic_cost)) + var/threat_spent = CONFIG_GET(number/dynamic_summon_magic_cost) + mode.spend_threat(threat_spent) + mode.threat_log += "[worldtime2text()]: Wizard spent [threat_spent] on summon magic." return 1 /datum/spellbook_entry/summon/events @@ -545,7 +549,9 @@ to_chat(user, "You have cast summon events.") if(istype(SSticker.mode,/datum/game_mode/dynamic) && times == 0) var/datum/game_mode/dynamic/mode = SSticker.mode - mode.spend_threat(CONFIG_GET(number/dynamic_summon_events_cost)) + var/threat_spent = CONFIG_GET(number/dynamic_summon_events_cost) + mode.spend_threat(threat_spent) + mode.threat_log += "[worldtime2text()]: Wizard spent [threat_spent] on summon events." return 1 /datum/spellbook_entry/summon/events/GetInfo()