From 0c97f42d63e61b87ceaec8d3b33235c8506e7d5f Mon Sep 17 00:00:00 2001 From: Leo Date: Tue, 21 Mar 2017 11:41:49 -0300 Subject: [PATCH] Adds a cancel verb when choosing whether a command report is public or not (#25295) --- code/modules/admin/verbs/randomverbs.dm | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/code/modules/admin/verbs/randomverbs.dm b/code/modules/admin/verbs/randomverbs.dm index 5503c7cde3a..d9f27abda6e 100644 --- a/code/modules/admin/verbs/randomverbs.dm +++ b/code/modules/admin/verbs/randomverbs.dm @@ -453,13 +453,16 @@ Traitors and the like can also be revived with the previous role mostly intact. if(!input) return - var/confirm = alert(src, "Do you want to announce the contents of the report to the crew?", "Announce", "Yes", "No") + var/confirm = alert(src, "Do you want to announce the contents of the report to the crew?", "Announce", "Yes", "No", "Cancel") var/announce_command_report = TRUE - if(confirm == "Yes") - priority_announce(input, null, 'sound/AI/commandreport.ogg') - announce_command_report = FALSE + switch(confirm) + if("Yes") + priority_announce(input, null, 'sound/AI/commandreport.ogg') + announce_command_report = FALSE + if("Cancel") + return - print_command_report(input,"[confirm=="Yes" ? "" : "Classified "][command_name()] Update",announce=announce_command_report) + print_command_report(input, "[announce_command_report ? "Classified " : ""][command_name()] Update", announce_command_report) log_admin("[key_name(src)] has created a command report: [input]") message_admins("[key_name_admin(src)] has created a command report")