mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 10:43:20 +00:00
Make stack amount var private
This commit is contained in:
@@ -62,10 +62,8 @@
|
||||
var/stack = params["stack"]
|
||||
if(machine.stack_storage[stack] > 0)
|
||||
var/stacktype = machine.stack_paths[stack]
|
||||
var/obj/item/stack/material/S = new stacktype(get_turf(machine.output))
|
||||
S.amount = machine.stack_storage[stack]
|
||||
new stacktype(get_turf(machine.output), machine.stack_storage[stack])
|
||||
machine.stack_storage[stack] = 0
|
||||
S.update_icon()
|
||||
. = TRUE
|
||||
|
||||
add_fingerprint(usr)
|
||||
@@ -125,7 +123,7 @@
|
||||
var/obj/item/stack/material/S = O
|
||||
var/matname = S.material.name
|
||||
if(!isnull(stack_storage[matname]))
|
||||
stack_storage[matname] += S.amount
|
||||
stack_storage[matname] += S.get_amount()
|
||||
qdel(S)
|
||||
else
|
||||
O.loc = output.loc
|
||||
@@ -136,10 +134,8 @@
|
||||
for(var/sheet in stack_storage)
|
||||
if(stack_storage[sheet] >= stack_amt)
|
||||
var/stacktype = stack_paths[sheet]
|
||||
var/obj/item/stack/material/S = new stacktype (get_turf(output))
|
||||
S.amount = stack_amt
|
||||
new stacktype (get_turf(output), stack_amt)
|
||||
stack_storage[sheet] -= stack_amt
|
||||
S.update_icon()
|
||||
|
||||
if(console)
|
||||
console.updateUsrDialog()
|
||||
|
||||
Reference in New Issue
Block a user