diff --git a/code/controllers/subsystem/communications.dm b/code/controllers/subsystem/communications.dm index 2f57248b6cf..992835072b3 100644 --- a/code/controllers/subsystem/communications.dm +++ b/code/controllers/subsystem/communications.dm @@ -13,6 +13,11 @@ SUBSYSTEM_DEF(communications) /// Are we trying to send a cross-station message that contains soft-filtered words? If so, flip to TRUE to extend the time admins have to cancel the message. var/soft_filtering = FALSE + /// A list of footnote datums, to be added to the bottom of the roundstart command report. + var/list/command_report_footnotes = list() + /// A counter of conditions that are blocking the command report from printing. Counter incremements up for every blocking condition, and de-incrememnts when it is complete. + var/block_command_report = 0 + /datum/controller/subsystem/communications/proc/can_announce(mob/living/user, is_silicon) if(is_silicon && COOLDOWN_FINISHED(src, silicon_message_cooldown)) return TRUE diff --git a/code/game/gamemodes/dynamic/dynamic.dm b/code/game/gamemodes/dynamic/dynamic.dm index c8f1cc3952a..c632f8386d7 100644 --- a/code/game/gamemodes/dynamic/dynamic.dm +++ b/code/game/gamemodes/dynamic/dynamic.dm @@ -294,6 +294,10 @@ GLOBAL_VAR_INIT(dynamic_forced_threat_level, -1) return ..() /datum/game_mode/dynamic/proc/send_intercept() + if(SScommunications.block_command_report) //If we don't want the report to be printed just yet, we put it off until it's ready + addtimer(CALLBACK(src, PROC_REF(send_intercept)), 10 SECONDS) + return + . = "Nanotrasen Department of Intelligence Threat Advisory, Spinward Sector, TCD [time2text(world.realtime, "DDD, MMM DD")], [CURRENT_STATION_YEAR]:
" switch(round(shown_threat)) if(0 to 19) @@ -333,6 +337,8 @@ GLOBAL_VAR_INIT(dynamic_forced_threat_level, -1) generate_station_goals(greenshift) . += generate_station_goal_report() . += generate_station_trait_report() + if(length(SScommunications.command_report_footnotes)) + . += generate_report_footnote() print_command_report(., "Central Command Status Summary", announce=FALSE) if(greenshift) diff --git a/code/game/gamemodes/game_mode.dm b/code/game/gamemodes/game_mode.dm index 5b899b774c8..b868b4141cd 100644 --- a/code/game/gamemodes/game_mode.dm +++ b/code/game/gamemodes/game_mode.dm @@ -98,6 +98,16 @@ return "
Identified shift divergencies:
" + trait_list_string return +/datum/game_mode/proc/generate_report_footnote() + var/footnote_pile = "" + + for(var/datum/command_footnote/footnote in SScommunications.command_report_footnotes) + footnote_pile += "[footnote.message]
" + footnote_pile += "[footnote.signature]
" + footnote_pile += "
" + + return "
Additional Notes:

" + footnote_pile + /proc/reopen_roundstart_suicide_roles() var/include_command = CONFIG_GET(flag/reopen_roundstart_suicide_roles_command_positions) var/list/reopened_jobs = list() diff --git a/code/modules/admin/admin_verbs.dm b/code/modules/admin/admin_verbs.dm index 33cceb33497..913e56effe6 100644 --- a/code/modules/admin/admin_verbs.dm +++ b/code/modules/admin/admin_verbs.dm @@ -137,6 +137,8 @@ GLOBAL_LIST_INIT(admin_verbs_fun, list( /client/proc/admin_away, /client/proc/add_mob_ability, /client/proc/remove_mob_ability, + /client/proc/command_report_footnote, + /client/proc/delay_command_report, /datum/admins/proc/station_traits_panel, /client/proc/spawn_pollution, // SKYRAT EDIT ADDITION /client/proc/spawn_liquid, // SKYRAT EDIT ADDITION diff --git a/code/modules/admin/verbs/adminevents.dm b/code/modules/admin/verbs/adminevents.dm index d91e009dd78..ff8b7a7df43 100644 --- a/code/modules/admin/verbs/adminevents.dm +++ b/code/modules/admin/verbs/adminevents.dm @@ -385,3 +385,50 @@ message_admins("[key_name_admin(usr)] removed ability [ability_name] from mob [marked_mob].") log_admin("[key_name(usr)] removed mob ability [ability_name] from mob [marked_mob].") SSblackbox.record_feedback("tally", "admin_verb", 1, "Remove Mob Ability") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! + + +/client/proc/command_report_footnote() + set category = "Admin.Events" + set name = "Command Report Footnote" + set desc = "Adds a footnote to the roundstart command report." + + if(!check_rights(R_ADMIN)) + return + + var/datum/command_footnote/command_report_footnote = new /datum/command_footnote() + SScommunications.block_command_report++ //Add a blocking condition to the counter until the inputs are done. + + command_report_footnote.message = tgui_input_text(usr, "This message will be attached to the bottom of the roundstart threat report. Be sure to delay the roundstart report if you need extra time.", "P.S.") + + if(!command_report_footnote.message) + return + + command_report_footnote.signature = tgui_input_text(usr, "Whose signature will appear on this footnote?", "Also sign here, here, aaand here.") + + if(!command_report_footnote.signature) + command_report_footnote.signature = "Classified" + + SScommunications.command_report_footnotes += command_report_footnote + SScommunications.block_command_report-- + + message_admins("[usr] has added a footnote to the command report: [command_report_footnote.message], signed [command_report_footnote.signature]") + +/datum/command_footnote + var/message + var/signature + +/client/proc/delay_command_report() + set category = "Admin.Events" + set name = "Delay Command Report" + set desc = "Prevents the roundstart command report from being sent until toggled." + + if(!check_rights(R_ADMIN)) + return + + if(SScommunications.block_command_report) //If it's anything other than 0, decrease. If 0, increase. + SScommunications.block_command_report-- + message_admins("[usr] has enabled the roundstart command report.") + else + SScommunications.block_command_report++ + message_admins("[usr] has delayed the roundstart command report.") +