From aa8ff1a1e2c366c67fd7e23ef82002b50ab2194b Mon Sep 17 00:00:00 2001 From: Drathek <76988376+Drulikar@users.noreply.github.com> Date: Sat, 3 Feb 2024 01:24:35 -0800 Subject: [PATCH] [s] Fixes for new 515 features (#5633) # About the pull request Apparently these changes are features. Thanks 515. But in reality, this desperately needs to be tguified. # Explain why it's good for the game The "features" are not good for the game. # Testing Photographs and Procedure
Screenshots & Videos Put screenshots and videos here with an empty line between the screenshots and the `
` tags.
# Changelog If you know you know. --- code/game/objects/items/stacks/stack.dm | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/code/game/objects/items/stacks/stack.dm b/code/game/objects/items/stacks/stack.dm index ab56882de6f0..f8a6af3cf24f 100644 --- a/code/game/objects/items/stacks/stack.dm +++ b/code/game/objects/items/stacks/stack.dm @@ -144,7 +144,9 @@ Also change the icon to reflect the amount of sheets, if possible.*/ list_recipes(usr, text2num(href_list["sublist"])) if(href_list["make"]) - if(amount < 1) qdel(src) //Never should happen + if(amount < 1) + qdel(src) //Never should happen + return var/list/recipes_list = recipes if(href_list["sublist"]) @@ -152,7 +154,11 @@ Also change the icon to reflect the amount of sheets, if possible.*/ recipes_list = srl.recipes var/datum/stack_recipe/R = recipes_list[text2num(href_list["make"])] var/multiplier = text2num(href_list["multiplier"]) - if(!isnum(multiplier)) + if(multiplier != multiplier) // isnan + message_admins("[key_name_admin(usr)] has attempted to multiply [src] with NaN") + return + if(!isnum(multiplier)) // this used to block nan... + message_admins("[key_name_admin(usr)] has attempted to multiply [src] with !isnum") return multiplier = round(multiplier) if(multiplier < 1)