From d665940bb9078de88ea2ac1bba8860540f3afdc5 Mon Sep 17 00:00:00 2001 From: Sparky Date: Sun, 2 Jun 2024 19:43:24 +0100 Subject: [PATCH] Coat Rack Removal Fix (#19300) Fixes removing both the hat and coat from coat racks when only one is selected. --- code/game/objects/structures/coatrack.dm | 6 ++++-- html/changelogs/coat-rack-fix.yml | 5 +++++ 2 files changed, 9 insertions(+), 2 deletions(-) create mode 100644 html/changelogs/coat-rack-fix.yml diff --git a/code/game/objects/structures/coatrack.dm b/code/game/objects/structures/coatrack.dm index 8f26d9b2e1c..abd61b51b53 100644 --- a/code/game/objects/structures/coatrack.dm +++ b/code/game/objects/structures/coatrack.dm @@ -11,18 +11,20 @@ /obj/structure/coatrack/attack_hand(mob/user as mob) if(use_check_and_message(user)) return + add_fingerprint(user) if(coat && hat) var/response = "" response = alert(user, "Do you remove the coat, or the hat?", "Coat Rack Selection", "Coat", "Hat", "Cancel") if(response == "Coat") remove_coat(user) + return if(response == "Hat") remove_hat(user) + return if(coat) remove_coat(user) - if(hat) + else if(hat) remove_hat(user) - add_fingerprint(user) return /obj/structure/coatrack/proc/remove_coat(mob/user as mob) diff --git a/html/changelogs/coat-rack-fix.yml b/html/changelogs/coat-rack-fix.yml new file mode 100644 index 00000000000..0543bb6d4a4 --- /dev/null +++ b/html/changelogs/coat-rack-fix.yml @@ -0,0 +1,5 @@ +author: Sparky_hotdog + +delete-after: True +changes: + - bugfix: "Fixes coat racks always removing both hats and coats, when only one is selected."