From cf8652b17b0cab0384dfea57540b907e8c1db66d Mon Sep 17 00:00:00 2001 From: forest2001 <41653574+realforest2001@users.noreply.github.com> Date: Sun, 25 Feb 2024 19:41:28 +0000 Subject: [PATCH 1/4] Changes some event verb permissions around. (#5809) # About the pull request As title # Explain why it's good for the game Simplification. # Changelog :cl: admin: Mods can now run votes where appropriate. admin: Moved a few event verbs from Admin level to Senior Mod. admin: Added a log to creating new bank accounts. /:cl: --- code/controllers/subsystem/vote.dm | 2 +- code/modules/admin/admin_verbs.dm | 6 ++---- code/modules/admin/verbs/debug.dm | 2 ++ 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/code/controllers/subsystem/vote.dm b/code/controllers/subsystem/vote.dm index 33967fab1004..2438577a1771 100644 --- a/code/controllers/subsystem/vote.dm +++ b/code/controllers/subsystem/vote.dm @@ -525,7 +525,7 @@ GLOBAL_LIST_INIT(possible_vote_types, list( if(!(params["vote_type"] in GLOB.possible_vote_types)) return - if(!check_rights(R_ADMIN)) + if(!check_rights(R_MOD)) var/list/vote_type = GLOB.possible_vote_types[params["vote_type"]] if(vote_type["admin_only"]) return diff --git a/code/modules/admin/admin_verbs.dm b/code/modules/admin/admin_verbs.dm index f3eae1447ba0..d27e07329a94 100644 --- a/code/modules/admin/admin_verbs.dm +++ b/code/modules/admin/admin_verbs.dm @@ -111,6 +111,7 @@ GLOBAL_LIST_INIT(admin_verbs_minor_event, list( /client/proc/cmd_admin_change_custom_event, /datum/admins/proc/admin_force_distress, /datum/admins/proc/admin_force_ERT_shuttle, + /client/proc/enable_event_mob_verbs, /client/proc/force_hijack, /datum/admins/proc/force_predator_round, //Force spawns a predator round. /client/proc/adjust_predator_round, @@ -141,7 +142,6 @@ GLOBAL_LIST_INIT(admin_verbs_minor_event, list( )) GLOBAL_LIST_INIT(admin_verbs_major_event, list( - /client/proc/enable_event_mob_verbs, /client/proc/cmd_admin_dress_all, /client/proc/free_all_mobs_in_view, /client/proc/drop_bomb, @@ -238,6 +238,7 @@ GLOBAL_LIST_INIT(debug_verbs, list( )) GLOBAL_LIST_INIT(admin_verbs_possess, list( + /client/proc/cmd_assume_direct_control, /client/proc/possess, /client/proc/release )) @@ -262,10 +263,7 @@ GLOBAL_LIST_INIT(admin_mob_event_verbs_hideable, list( /client/proc/editappear, /client/proc/cmd_admin_addhud, /client/proc/cmd_admin_change_their_hivenumber, - /client/proc/cmd_assume_direct_control, /client/proc/free_mob_for_ghosts, - /client/proc/possess, - /client/proc/release, /client/proc/cmd_admin_grantfullaccess, /client/proc/cmd_admin_grantallskills, /client/proc/admin_create_account diff --git a/code/modules/admin/verbs/debug.dm b/code/modules/admin/verbs/debug.dm index ede1cd029d9d..c614b8d4d512 100644 --- a/code/modules/admin/verbs/debug.dm +++ b/code/modules/admin/verbs/debug.dm @@ -283,6 +283,8 @@ account_user.mind.store_memory(remembered_info) account_user.mind.initial_account = generated_account + log_admin("[key_name(usr)] has created a new bank account for [key_name(account_user)].") + /client/proc/cmd_assume_direct_control(mob/M in GLOB.mob_list) set name = "Control Mob" set desc = "Assume control of the mob" From f9f229a118cac4e2b82a2135f31b13b856b05086 Mon Sep 17 00:00:00 2001 From: cm13-github <128137806+cm13-github@users.noreply.github.com> Date: Sun, 25 Feb 2024 19:49:29 +0000 Subject: [PATCH 2/4] Automatic changelog for PR #5809 [ci skip] --- html/changelogs/AutoChangeLog-pr-5809.yml | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 html/changelogs/AutoChangeLog-pr-5809.yml diff --git a/html/changelogs/AutoChangeLog-pr-5809.yml b/html/changelogs/AutoChangeLog-pr-5809.yml new file mode 100644 index 000000000000..bda416105a69 --- /dev/null +++ b/html/changelogs/AutoChangeLog-pr-5809.yml @@ -0,0 +1,6 @@ +author: "realforest2001" +delete-after: True +changes: + - admin: "Mods can now run votes where appropriate." + - admin: "Moved a few event verbs from Admin level to Senior Mod." + - admin: "Added a log to creating new bank accounts." \ No newline at end of file From 723b6c2a259e20bdf32390a6119fa4d020c7e0d7 Mon Sep 17 00:00:00 2001 From: harryob Date: Sun, 25 Feb 2024 20:46:47 +0000 Subject: [PATCH 3/4] makes marking more effective for admins (#5779) marking a ticket now actually stops others from interacting from it. other admins can still override it by hitting "mark" themselves, and them "override" and doing whatever they want to it. :cl: admin: marking a ticket now actually stops other people from messing with your marked ticket /:cl: fixes #5547 --- code/modules/admin/verbs/adminhelp.dm | 22 ++++++++++++++++++++++ code/modules/admin/verbs/adminpm.dm | 2 +- 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/code/modules/admin/verbs/adminhelp.dm b/code/modules/admin/verbs/adminhelp.dm index 5f10b8d24d22..4b52f03c1ec8 100644 --- a/code/modules/admin/verbs/adminhelp.dm +++ b/code/modules/admin/verbs/adminhelp.dm @@ -469,6 +469,11 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new) /datum/admin_help/proc/Close(key_name = key_name_admin(usr), silent = FALSE) if(state != AHELP_ACTIVE) return + + if(marked_admin != usr.key) + to_chat(usr, SPAN_WARNING("This ticket is currently marked by [marked_admin]. Please override their mark to interact with this ticket!")) + return + RemoveActive() state = AHELP_CLOSED GLOB.ahelp_tickets.ListInsert(src) @@ -483,6 +488,11 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new) /datum/admin_help/proc/Resolve(key_name = key_name_admin(usr), silent = FALSE) if(state != AHELP_ACTIVE) return + + if(marked_admin != usr.key) + to_chat(usr, SPAN_WARNING("This ticket is currently marked by [marked_admin]. Please override their mark to interact with this ticket!")) + return + RemoveActive() state = AHELP_RESOLVED GLOB.ahelp_tickets.ListInsert(src) @@ -501,6 +511,10 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new) if(state != AHELP_ACTIVE || !initial_message) return + if(marked_admin != usr.key) + to_chat(usr, SPAN_WARNING("This ticket is currently marked by [marked_admin]. Please override their mark to interact with this ticket!")) + return + if(!initiator.current_mhelp) initiator.current_mhelp = new(initiator) @@ -559,6 +573,10 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new) if(state != AHELP_ACTIVE) return + if(marked_admin != usr.key) + to_chat(usr, SPAN_WARNING("This ticket is currently marked by [marked_admin]. Please override their mark to interact with this ticket!")) + return + if(initiator) initiator.giveadminhelpverb() @@ -582,6 +600,10 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new) to_chat(usr, SPAN_WARNING("This ticket is already closed!")) return + if(marked_admin != usr.key) + to_chat(usr, SPAN_WARNING("This ticket is currently marked by [marked_admin]. Please override their mark to interact with this ticket!")) + return + var/chosen = tgui_input_list(usr, "Which auto response do you wish to send?", "AutoReply", GLOB.adminreplies) var/datum/autoreply/admin/response = GLOB.adminreplies[chosen] diff --git a/code/modules/admin/verbs/adminpm.dm b/code/modules/admin/verbs/adminpm.dm index e5fed9db2fc4..a9a3a90ff35a 100644 --- a/code/modules/admin/verbs/adminpm.dm +++ b/code/modules/admin/verbs/adminpm.dm @@ -60,7 +60,7 @@ var/message_prompt = "Message:" - if((AH?.opening_responders && length(AH.ticket_interactions) == 1 ) || (AH?.marked_admin && AH?.marked_admin != usr.key) && length(AH.ticket_interactions) == 2) + if((AH?.opening_responders && length(AH.ticket_interactions) == 1 ) || ((AH?.marked_admin && AH?.marked_admin != usr.key) && length(AH.ticket_interactions) == 2)) SEND_SOUND(src, sound('sound/machines/buzz-sigh.ogg', volume=30)) message_prompt += "\n\n**This ticket is already being responded to by: [length(AH.opening_responders) ? english_list(AH.opening_responders) : AH.marked_admin]**" From f6a870a2014915aa9c2a9f17d913f0ab6a1ccb27 Mon Sep 17 00:00:00 2001 From: cm13-github <128137806+cm13-github@users.noreply.github.com> Date: Sun, 25 Feb 2024 20:55:47 +0000 Subject: [PATCH 4/4] Automatic changelog for PR #5779 [ci skip] --- html/changelogs/AutoChangeLog-pr-5779.yml | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 html/changelogs/AutoChangeLog-pr-5779.yml diff --git a/html/changelogs/AutoChangeLog-pr-5779.yml b/html/changelogs/AutoChangeLog-pr-5779.yml new file mode 100644 index 000000000000..e541ab112c5c --- /dev/null +++ b/html/changelogs/AutoChangeLog-pr-5779.yml @@ -0,0 +1,4 @@ +author: "harryob" +delete-after: True +changes: + - admin: "marking a ticket now actually stops other people from messing with your marked ticket" \ No newline at end of file