From 93ed3d812d770b373d77acb95d1e09eaa68b72af Mon Sep 17 00:00:00 2001 From: FabianK3 <21039694+FabianK3@users.noreply.github.com> Date: Mon, 1 Dec 2025 00:10:00 +0100 Subject: [PATCH] Fix printer handout runtime (#21637) # Summary This PR fixes a runtime when printers eject paper without a mob being nearby (mainly automated console printouts). ## Changes - Add mob check when printer handout papers. --- code/modules/modular_computers/hardware/nano_printer.dm | 3 ++- html/changelogs/fabiank3-fix-printer-handout.yml | 6 ++++++ 2 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 html/changelogs/fabiank3-fix-printer-handout.yml diff --git a/code/modules/modular_computers/hardware/nano_printer.dm b/code/modules/modular_computers/hardware/nano_printer.dm index 159f3f4fd71..6820b33093d 100644 --- a/code/modules/modular_computers/hardware/nano_printer.dm +++ b/code/modules/modular_computers/hardware/nano_printer.dm @@ -29,7 +29,8 @@ P.color = paper_color stored_paper-- - usr.put_in_hands(P, TRUE) + if(ismob(usr)) + usr.put_in_hands(P, TRUE) return P /obj/item/computer_hardware/nano_printer/attackby(obj/item/attacking_item, mob/user) diff --git a/html/changelogs/fabiank3-fix-printer-handout.yml b/html/changelogs/fabiank3-fix-printer-handout.yml new file mode 100644 index 00000000000..b475a19c2aa --- /dev/null +++ b/html/changelogs/fabiank3-fix-printer-handout.yml @@ -0,0 +1,6 @@ +author: FabianK3 + +delete-after: True + +changes: + - bugfix: "Fixed runtime error when paper is handed out by printers without a mob nearby."