Merge pull request #6343 from Nalarac/Circuits

Fixes Integrated Circuit Printer Taking Fractions of a Sheet
This commit is contained in:
Anewbe
2019-07-27 12:05:50 -05:00
committed by VirgoBot
parent 2f5957ee9f
commit 07811148c3
2 changed files with 37 additions and 1 deletions

View File

@@ -44,7 +44,7 @@
if(num < 1)
to_chat(user, span("warning", "\The [src] is too full to add more metal."))
return
if(stack.use(num))
if(stack.use(max(1, round(num)))) // We don't want to create stacks that aren't whole numbers
to_chat(user, span("notice", "You add [num] sheet\s to \the [src]."))
metal += num * metal_per_sheet
interact(user)