From c11d7ac148abddb7318565be3ef1c1565da58637 Mon Sep 17 00:00:00 2001 From: BurgerLUA Date: Sun, 6 May 2018 07:21:05 -0700 Subject: [PATCH] Fixed the Stack Machine from eating Materials (#4688) The stacker was coded to accept 1 sheet at a time, meaning that if you insert a stack of 50 sheets into the stacker, it will count that as only 1 sheet because people don't know how to code. --- code/modules/mining/machine_stacking.dm | 7 ++++--- html/changelogs/burgerbb-holy_fuck.yml | 6 ++++++ 2 files changed, 10 insertions(+), 3 deletions(-) create mode 100644 html/changelogs/burgerbb-holy_fuck.yml diff --git a/code/modules/mining/machine_stacking.dm b/code/modules/mining/machine_stacking.dm index a2172d44498..69abf00fdde 100644 --- a/code/modules/mining/machine_stacking.dm +++ b/code/modules/mining/machine_stacking.dm @@ -123,9 +123,10 @@ var/turf/T = get_turf(input) for(var/obj/item/O in T) if(!O) return - if(istype(O, /obj/item/stack) && stack_storage[O.type] != null) - stack_storage[O.type]++ - qdel(O) + var/obj/item/stack/S = O + if(istype(S) && stack_storage[S.type] != null) + stack_storage[S.type] += S.amount + qdel(S) else O.forceMove(output.loc) diff --git a/html/changelogs/burgerbb-holy_fuck.yml b/html/changelogs/burgerbb-holy_fuck.yml new file mode 100644 index 00000000000..ca156e2c31a --- /dev/null +++ b/html/changelogs/burgerbb-holy_fuck.yml @@ -0,0 +1,6 @@ +author: BurgerBB + +delete-after: True + +changes: + - rscadd: "Fixes the stacking machine from eating materials due to an oversight." \ No newline at end of file