diff --git a/code/modules/mining/equipment_locker.dm b/code/modules/mining/equipment_locker.dm index c6749528908..11bafb24e26 100644 --- a/code/modules/mining/equipment_locker.dm +++ b/code/modules/mining/equipment_locker.dm @@ -335,6 +335,8 @@ var/datum/design/alloy = files.FindDesignByID(alloy_id) if((check_access(inserted_id) || allowed(usr)) && alloy) var/desired = input("How many sheets?", "How many sheets would you like to smelt?", 1) as null|num + if(desired < 1) // Stops an exploit that lets you build negative alloys and get free materials + return var/smelt_amount = can_smelt_alloy(alloy) var/amount = round(min(desired,50,smelt_amount)) materials.use_amount(alloy.materials, amount)