diff --git a/code/game/machinery/doors/firedoor.dm b/code/game/machinery/doors/firedoor.dm
index 1635b448f4..3f26e7d80d 100644
--- a/code/game/machinery/doors/firedoor.dm
+++ b/code/game/machinery/doors/firedoor.dm
@@ -355,8 +355,7 @@
return
user.visible_message("[user] removes the wires from [src].", \
"You remove the wiring from [src], exposing the circuit board.")
- var/obj/item/stack/cable_coil/B = new(get_turf(src))
- B.amount = 5
+ new/obj/item/stack/cable_coil(get_turf(src), 5)
constructionStep = CONSTRUCTION_GUTTED
update_icon()
return
diff --git a/code/game/machinery/washing_machine.dm b/code/game/machinery/washing_machine.dm
index cdb12eaf5c..ab906f1bfa 100644
--- a/code/game/machinery/washing_machine.dm
+++ b/code/game/machinery/washing_machine.dm
@@ -65,8 +65,7 @@
return
/obj/item/stack/sheet/hairlesshide/machine_wash(obj/machinery/washing_machine/WM)
- var/obj/item/stack/sheet/wetleather/WL = new(loc)
- WL.amount = amount
+ new /obj/item/stack/sheet/wetleather(drop_location(), amount)
qdel(src)
/obj/item/clothing/suit/hooded/ian_costume/machine_wash(obj/machinery/washing_machine/WM)
diff --git a/code/game/mecha/equipment/tools/other_tools.dm b/code/game/mecha/equipment/tools/other_tools.dm
index 980b7170c1..0d1651c491 100644
--- a/code/game/mecha/equipment/tools/other_tools.dm
+++ b/code/game/mecha/equipment/tools/other_tools.dm
@@ -367,8 +367,7 @@
return ..()
/obj/item/mecha_parts/mecha_equipment/generator/proc/generator_init()
- fuel = new /obj/item/stack/sheet/mineral/plasma(src)
- fuel.amount = 0
+ fuel = new /obj/item/stack/sheet/mineral/plasma(src, 0)
/obj/item/mecha_parts/mecha_equipment/generator/detach()
STOP_PROCESSING(SSobj, src)
@@ -472,8 +471,7 @@
var/rad_per_cycle = 3
/obj/item/mecha_parts/mecha_equipment/generator/nuclear/generator_init()
- fuel = new /obj/item/stack/sheet/mineral/uranium(src)
- fuel.amount = 0
+ fuel = new /obj/item/stack/sheet/mineral/uranium(src, 0)
/obj/item/mecha_parts/mecha_equipment/generator/nuclear/critfail()
return
diff --git a/code/game/mecha/equipment/tools/work_tools.dm b/code/game/mecha/equipment/tools/work_tools.dm
index 2054a6ba9a..96adece298 100644
--- a/code/game/mecha/equipment/tools/work_tools.dm
+++ b/code/game/mecha/equipment/tools/work_tools.dm
@@ -301,8 +301,7 @@
/obj/item/mecha_parts/mecha_equipment/cable_layer/Initialize()
. = ..()
- cable = new(src)
- cable.amount = 0
+ cable = new(src, 0)
/obj/item/mecha_parts/mecha_equipment/cable_layer/can_attach(obj/mecha/working/M)
if(..())
@@ -333,8 +332,7 @@
if(to_load)
to_load = min(target.amount, to_load)
if(!cable)
- cable = new(src)
- cable.amount = 0
+ cable = new(src, 0)
cable.amount += to_load
target.use(to_load)
occupant_message("[to_load] meters of cable successfully loaded.")
@@ -358,8 +356,7 @@
m = min(m, cable.amount)
if(m)
use_cable(m)
- var/obj/item/stack/cable_coil/CC = new (get_turf(chassis))
- CC.amount = m
+ new /obj/item/stack/cable_coil(get_turf(chassis), m)
else
occupant_message("There's no more cable on the reel.")
return
diff --git a/code/game/objects/items/apc_frame.dm b/code/game/objects/items/apc_frame.dm
index 5048f6ed2d..87b90d5b8f 100644
--- a/code/game/objects/items/apc_frame.dm
+++ b/code/game/objects/items/apc_frame.dm
@@ -104,8 +104,7 @@
to_chat(user, "There is another network terminal here!")
return
else
- var/obj/item/stack/cable_coil/C = new /obj/item/stack/cable_coil(T)
- C.amount = 10
+ new /obj/item/stack/cable_coil(T, 10)
to_chat(user, "You cut the cables and disassemble the unused power terminal.")
qdel(E)
return TRUE
diff --git a/code/game/objects/items/stacks/sheets/leather.dm b/code/game/objects/items/stacks/sheets/leather.dm
index cfccedcc3a..4eae35a98c 100644
--- a/code/game/objects/items/stacks/sheets/leather.dm
+++ b/code/game/objects/items/stacks/sheets/leather.dm
@@ -211,10 +211,9 @@ GLOBAL_LIST_INIT(sinew_recipes, list ( \
if(W.is_sharp())
playsound(loc, 'sound/weapons/slice.ogg', 50, 1, -1)
user.visible_message("[user] starts cutting hair off \the [src].", "You start cutting the hair off \the [src]...", "You hear the sound of a knife rubbing against flesh.")
- if(do_after(user,50, target = src))
+ if(do_after(user, 50, target = src))
to_chat(user, "You cut the hair from this [src.singular_name].")
- var/obj/item/stack/sheet/hairlesshide/HS = new(user.loc)
- HS.amount = 1
+ new /obj/item/stack/sheet/hairlesshide(user.drop_location(), 1)
use(1)
else
return ..()
@@ -228,21 +227,11 @@ GLOBAL_LIST_INIT(sinew_recipes, list ( \
if(exposed_temperature >= drying_threshold_temperature)
wetness--
if(wetness == 0)
- //Try locating an exisitng stack on the tile and add to there if possible
- for(var/obj/item/stack/sheet/leather/HS in src.loc)
- if(HS.amount < 50)
- HS.amount++
- src.use(1)
- wetness = initial(wetness)
- break
- //If it gets to here it means it did not find a suitable stack on the tile.
- var/obj/item/stack/sheet/leather/HS = new(src.loc)
- HS.amount = 1
+ new /obj/item/stack/sheet/leather(drop_location(), 1)
wetness = initial(wetness)
- src.use(1)
+ use(1)
/obj/item/stack/sheet/wetleather/microwave_act(obj/machinery/microwave/MW)
..()
- var/obj/item/stack/sheet/leather/L = new(loc)
- L.amount = amount
+ new /obj/item/stack/sheet/leather(drop_location(), amount)
qdel(src)
diff --git a/code/game/objects/items/stacks/sheets/light.dm b/code/game/objects/items/stacks/sheets/light.dm
index b4482a72db..b7c2d5b3f9 100644
--- a/code/game/objects/items/stacks/sheets/light.dm
+++ b/code/game/objects/items/stacks/sheets/light.dm
@@ -14,13 +14,12 @@
grind_results = list("silicon" = 20, "copper" = 5)
/obj/item/stack/light_w/attackby(obj/item/O, mob/user, params)
-
+ var/atom/Tsec = user.drop_location()
if(istype(O, /obj/item/wirecutters))
- var/obj/item/stack/cable_coil/CC = new (user.loc)
- CC.amount = 5
+ var/obj/item/stack/cable_coil/CC = new (Tsec, 5)
CC.add_fingerprint(user)
amount--
- var/obj/item/stack/sheet/glass/G = new (user.loc)
+ var/obj/item/stack/sheet/glass/G = new (Tsec)
G.add_fingerprint(user)
if(amount <= 0)
qdel(src)
@@ -28,7 +27,6 @@
else if(istype(O, /obj/item/stack/sheet/metal))
var/obj/item/stack/sheet/metal/M = O
if (M.use(1))
- use(1)
var/obj/item/L = new /obj/item/stack/tile/light(user.loc)
to_chat(user, "You make a light tile.")
L.add_fingerprint(user)
diff --git a/code/game/objects/items/stacks/sheets/sheet_types.dm b/code/game/objects/items/stacks/sheets/sheet_types.dm
index 6109f6b0d0..b3af8b9b33 100644
--- a/code/game/objects/items/stacks/sheets/sheet_types.dm
+++ b/code/game/objects/items/stacks/sheets/sheet_types.dm
@@ -121,6 +121,9 @@ GLOBAL_LIST_INIT(metal_recipes, list ( \
/obj/item/stack/sheet/metal/twenty
amount = 20
+/obj/item/stack/sheet/metal/ten
+ amount = 10
+
/obj/item/stack/sheet/metal/five
amount = 5
diff --git a/code/game/objects/items/stacks/stack.dm b/code/game/objects/items/stacks/stack.dm
index e67efb0c8a..4d5bf2a449 100644
--- a/code/game/objects/items/stacks/stack.dm
+++ b/code/game/objects/items/stacks/stack.dm
@@ -33,10 +33,13 @@
return
return TRUE
-/obj/item/stack/Initialize(mapload, new_amount=null , merge = TRUE)
+/obj/item/stack/Initialize(mapload, new_amount, merge = TRUE)
. = ..()
- if(new_amount)
+ if(new_amount != null)
amount = new_amount
+ while(amount > max_amount)
+ amount -= max_amount
+ new type(loc, max_amount, FALSE)
if(!merge_type)
merge_type = type
if(merge)
diff --git a/code/game/objects/structures/ai_core.dm b/code/game/objects/structures/ai_core.dm
index 0a6dfaa1cf..ed797e4256 100644
--- a/code/game/objects/structures/ai_core.dm
+++ b/code/game/objects/structures/ai_core.dm
@@ -147,8 +147,7 @@
to_chat(user, "You remove the cables.")
state = SCREWED_CORE
update_icon()
- var/obj/item/stack/cable_coil/A = new /obj/item/stack/cable_coil( loc )
- A.amount = 5
+ new /obj/item/stack/cable_coil(drop_location(), 5)
return
if(istype(P, /obj/item/stack/sheet/rglass))
diff --git a/code/game/objects/structures/crates_lockers/closets/syndicate.dm b/code/game/objects/structures/crates_lockers/closets/syndicate.dm
index 2214869098..7687c42c3c 100644
--- a/code/game/objects/structures/crates_lockers/closets/syndicate.dm
+++ b/code/game/objects/structures/crates_lockers/closets/syndicate.dm
@@ -1,3 +1,4 @@
+<<<<<<< HEAD
/obj/structure/closet/syndicate
name = "armory closet"
desc = "Why is this here?"
@@ -113,3 +114,120 @@
for(var/res in resources)
var/obj/item/stack/R = new res(src)
R.amount = R.max_amount
+=======
+/obj/structure/closet/syndicate
+ name = "armory closet"
+ desc = "Why is this here?"
+ icon_state = "syndicate"
+
+/obj/structure/closet/syndicate/personal
+ desc = "It's a personal storage unit for operative gear."
+
+/obj/structure/closet/syndicate/personal/PopulateContents()
+ ..()
+ new /obj/item/clothing/under/syndicate(src)
+ new /obj/item/clothing/shoes/sneakers/black(src)
+ new /obj/item/radio/headset/syndicate(src)
+ new /obj/item/ammo_box/magazine/m10mm(src)
+ new /obj/item/storage/belt/military(src)
+ new /obj/item/crowbar/red(src)
+ new /obj/item/clothing/glasses/night(src)
+
+/obj/structure/closet/syndicate/nuclear
+ desc = "It's a storage unit for a Syndicate boarding party."
+
+/obj/structure/closet/syndicate/nuclear/PopulateContents()
+ for(var/i in 1 to 5)
+ new /obj/item/ammo_box/magazine/m10mm(src)
+ new /obj/item/storage/box/flashbangs(src)
+ new /obj/item/storage/box/teargas(src)
+ new /obj/item/storage/backpack/duffelbag/syndie/med(src)
+ new /obj/item/pda/syndicate(src)
+
+/obj/structure/closet/syndicate/resources
+ desc = "An old, dusty locker."
+
+/obj/structure/closet/syndicate/resources/PopulateContents()
+ ..()
+ var/common_min = 30 //Minimum amount of minerals in the stack for common minerals
+ var/common_max = 50 //Maximum amount of HONK in the stack for HONK common minerals
+ var/rare_min = 5 //Minimum HONK of HONK in the stack HONK HONK rare minerals
+ var/rare_max = 20 //Maximum HONK HONK HONK in the HONK for HONK rare HONK
+
+
+ var/pickednum = rand(1, 50)
+
+ //Sad trombone
+ if(pickednum == 1)
+ var/obj/item/paper/P = new /obj/item/paper(src)
+ P.name = "\improper IOU"
+ P.info = "Sorry man, we needed the money so we sold your stash. It's ok, we'll double our money for sure this time!"
+
+ //Metal (common ore)
+ if(pickednum >= 2)
+ new /obj/item/stack/sheet/metal(src, rand(common_min, common_max))
+
+ //Glass (common ore)
+ if(pickednum >= 5)
+ new /obj/item/stack/sheet/glass(src, rand(common_min, common_max))
+
+ //Plasteel (common ore) Because it has a million more uses then plasma
+ if(pickednum >= 10)
+ new /obj/item/stack/sheet/plasteel(src, rand(common_min, common_max))
+
+ //Plasma (rare ore)
+ if(pickednum >= 15)
+ new /obj/item/stack/sheet/mineral/plasma(src, rand(rare_min, rare_max))
+
+ //Silver (rare ore)
+ if(pickednum >= 20)
+ new /obj/item/stack/sheet/mineral/silver(src, rand(rare_min, rare_max))
+
+ //Gold (rare ore)
+ if(pickednum >= 30)
+ new /obj/item/stack/sheet/mineral/gold(src, rand(rare_min, rare_max))
+
+ //Uranium (rare ore)
+ if(pickednum >= 40)
+ new /obj/item/stack/sheet/mineral/uranium(src, rand(rare_min, rare_max))
+
+ //Titanium (rare ore)
+ if(pickednum >= 40)
+ new /obj/item/stack/sheet/mineral/titanium(src, rand(rare_min, rare_max))
+
+ //Plastitanium (rare ore)
+ if(pickednum >= 40)
+ new /obj/item/stack/sheet/mineral/plastitanium(src, rand(rare_min, rare_max))
+
+ //Diamond (rare HONK)
+ if(pickednum >= 45)
+ new /obj/item/stack/sheet/mineral/diamond(src, rand(rare_min, rare_max))
+
+ //Jetpack (You hit the jackpot!)
+ if(pickednum == 50)
+ new /obj/item/tank/jetpack/carbondioxide(src)
+
+/obj/structure/closet/syndicate/resources/everything
+ desc = "It's an emergency storage closet for repairs."
+
+/obj/structure/closet/syndicate/resources/everything/PopulateContents()
+ var/list/resources = list(
+ /obj/item/stack/sheet/metal,
+ /obj/item/stack/sheet/glass,
+ /obj/item/stack/sheet/mineral/gold,
+ /obj/item/stack/sheet/mineral/silver,
+ /obj/item/stack/sheet/mineral/plasma,
+ /obj/item/stack/sheet/mineral/uranium,
+ /obj/item/stack/sheet/mineral/diamond,
+ /obj/item/stack/sheet/mineral/bananium,
+ /obj/item/stack/sheet/plasteel,
+ /obj/item/stack/sheet/mineral/titanium,
+ /obj/item/stack/sheet/mineral/plastitanium,
+ /obj/item/stack/rods
+ )
+
+ for(var/i = 0, i<2, i++)
+ for(var/res in resources)
+ var/obj/item/stack/R = res
+ new res(src, initial(R.max_amount))
+>>>>>>> e8304c1... Merge pull request #37760 from YPOQ/stackfix
diff --git a/code/modules/antagonists/swarmer/swarmer.dm b/code/modules/antagonists/swarmer/swarmer.dm
index 4d6887f3e8..3ea2e1d739 100644
--- a/code/modules/antagonists/swarmer/swarmer.dm
+++ b/code/modules/antagonists/swarmer/swarmer.dm
@@ -493,10 +493,10 @@
D.pixel_z = target.pixel_z
if(do_mob(src, target, 100))
to_chat(src, "Dismantling complete.")
- var/obj/item/stack/sheet/metal/M = new /obj/item/stack/sheet/metal(target.loc)
- M.amount = 5
+ var/atom/Tsec = target.drop_location()
+ new /obj/item/stack/sheet/metal(Tsec, 5)
for(var/obj/item/I in target.component_parts)
- I.forceMove(M.drop_location())
+ I.forceMove(Tsec)
var/obj/effect/temp_visual/swarmer/disintegration/N = new /obj/effect/temp_visual/swarmer/disintegration(get_turf(target))
N.pixel_x = target.pixel_x
N.pixel_y = target.pixel_y
@@ -505,7 +505,7 @@
if(istype(target, /obj/machinery/computer))
var/obj/machinery/computer/C = target
if(C.circuit)
- C.circuit.forceMove(M.drop_location())
+ C.circuit.forceMove(Tsec)
qdel(target)
diff --git a/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm b/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm
index 2522ec9cf2..edc2305261 100644
--- a/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm
+++ b/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm
@@ -299,8 +299,7 @@
qdel(S)
return TRUE
for(var/obj/item/stack/sheet/wetleather/WL in src)
- var/obj/item/stack/sheet/leather/L = new(drop_location())
- L.amount = WL.amount
+ new /obj/item/stack/sheet/leather(drop_location(), WL.amount)
qdel(WL)
return TRUE
return FALSE
diff --git a/code/modules/hydroponics/biogenerator.dm b/code/modules/hydroponics/biogenerator.dm
index 624394f878..6da117da88 100644
--- a/code/modules/hydroponics/biogenerator.dm
+++ b/code/modules/hydroponics/biogenerator.dm
@@ -262,8 +262,7 @@
if(!check_cost(D.materials, amount))
return FALSE
- var/obj/item/stack/product = new D.build_path(loc)
- product.amount = amount
+ new D.build_path(drop_location(), amount)
for(var/R in D.make_reagents)
beaker.reagents.add_reagent(R, D.make_reagents[R]*amount)
else
diff --git a/code/modules/hydroponics/grown/grass_carpet.dm b/code/modules/hydroponics/grown/grass_carpet.dm
index 630c072edb..8e55f8a15d 100644
--- a/code/modules/hydroponics/grown/grass_carpet.dm
+++ b/code/modules/hydroponics/grown/grass_carpet.dm
@@ -36,19 +36,8 @@
continue
grassAmt += 1 + round(G.seed.potency * tile_coefficient)
qdel(G)
- var/obj/item/stack/tile/GT = new stacktype(user.loc)
- while(grassAmt > GT.max_amount)
- GT.amount = GT.max_amount
- grassAmt -= GT.max_amount
- GT = new stacktype(user.loc)
- GT.amount = grassAmt
- for(var/obj/item/stack/tile/T in user.loc)
- if((T.type == stacktype) && (T.amount < T.max_amount))
- GT.merge(T)
- if(GT.amount <= 0)
- break
+ new stacktype(user.drop_location(), grassAmt)
qdel(src)
- return
// Carpet
/obj/item/seeds/grass/carpet
diff --git a/code/modules/mining/machine_redemption.dm b/code/modules/mining/machine_redemption.dm
index b7b3d91e54..d4735d1c75 100644
--- a/code/modules/mining/machine_redemption.dm
+++ b/code/modules/mining/machine_redemption.dm
@@ -303,13 +303,12 @@
desired = input("How many sheets?", "How many sheets would you like to smelt?", 1) as null|num
var/amount = round(min(desired,50,smelt_amount))
materials.use_amount(alloy.materials, amount)
- var/output = new alloy.build_path(src)
- if(istype(output, /obj/item/stack/sheet))
- var/obj/item/stack/sheet/produced_alloy = output
- produced_alloy.amount = amount
- unload_mineral(produced_alloy)
+ var/output
+ if(ispath(alloy.build_path, /obj/item/stack/sheet))
+ output = new alloy.build_path(src, amount)
else
- unload_mineral(output)
+ output = new alloy.build_path(src)
+ unload_mineral(output)
else
to_chat(usr, "Required access not found.")
return TRUE
diff --git a/code/modules/mining/machine_stacking.dm b/code/modules/mining/machine_stacking.dm
index e658f69395..f566a8f4a9 100644
--- a/code/modules/mining/machine_stacking.dm
+++ b/code/modules/mining/machine_stacking.dm
@@ -44,8 +44,7 @@
if(!(text2path(href_list["release"]) in machine.stack_list))
return //someone tried to spawn materials by spoofing hrefs
var/obj/item/stack/sheet/inp = machine.stack_list[text2path(href_list["release"])]
- var/obj/item/stack/sheet/out = new inp.type()
- out.amount = inp.amount
+ var/obj/item/stack/sheet/out = new inp.type(null, inp.amount)
inp.amount = 0
machine.unload_mineral(out)
@@ -81,14 +80,12 @@
/obj/machinery/mineral/stacking_machine/proc/process_sheet(obj/item/stack/sheet/inp)
if(!(inp.type in stack_list)) //It's the first of this sheet added
- var/obj/item/stack/sheet/s = new inp.type(src,0)
- s.amount = 0
+ var/obj/item/stack/sheet/s = new inp.type(src, 0)
stack_list[inp.type] = s
var/obj/item/stack/sheet/storage = stack_list[inp.type]
storage.amount += inp.amount //Stack the sheets
qdel(inp) //Let the old sheet garbage collect
while(storage.amount > stack_amt) //Get rid of excessive stackage
- var/obj/item/stack/sheet/out = new inp.type()
- out.amount = stack_amt
+ var/obj/item/stack/sheet/out = new inp.type(null, stack_amt)
unload_mineral(out)
storage.amount -= stack_amt
diff --git a/code/modules/mob/living/simple_animal/bot/floorbot.dm b/code/modules/mob/living/simple_animal/bot/floorbot.dm
index f0cc8285e8..f47f936db7 100644
--- a/code/modules/mob/living/simple_animal/bot/floorbot.dm
+++ b/code/modules/mob/living/simple_animal/bot/floorbot.dm
@@ -164,12 +164,7 @@
update_controls()
/mob/living/simple_animal/bot/floorbot/proc/empty_tiles()
- var/atom/Tsec = drop_location()
-
- while(specialtiles > initial(tiletype.max_amount))
- new tiletype(Tsec,initial(tiletype.max_amount))
- specialtiles -= initial(tiletype.max_amount)
- new tiletype(Tsec,specialtiles)
+ new tiletype(drop_location(), specialtiles)
specialtiles = 0
tiletype = null
@@ -378,8 +373,7 @@
if(prob(50))
drop_part(robot_arm, Tsec)
- var/obj/item/stack/tile/plasteel/T = new (Tsec)
- T.amount = 1
+ new /obj/item/stack/tile/plasteel(Tsec, 1)
do_sparks(3, TRUE, src)
..()
diff --git a/code/modules/power/port_gen.dm b/code/modules/power/port_gen.dm
index 7cea950ccc..7a6e313cd0 100644
--- a/code/modules/power/port_gen.dm
+++ b/code/modules/power/port_gen.dm
@@ -111,13 +111,8 @@
/obj/machinery/power/port_gen/pacman/DropFuel()
if(sheets)
- var/fail_safe = FALSE
- while(sheets > 0 && fail_safe < 100)
- fail_safe += 1
- var/obj/item/stack/sheet/S = new sheet_path(loc)
- var/amount = min(sheets, S.max_amount)
- S.amount = amount
- sheets -= amount
+ new sheet_path(drop_location(), sheets)
+ sheets = 0
/obj/machinery/power/port_gen/pacman/UseFuel()
var/needed_sheets = 1 / (time_per_sheet * consumption / power_output)
diff --git a/code/modules/power/solar.dm b/code/modules/power/solar.dm
index f4c11009d1..d7e0bc66bc 100644
--- a/code/modules/power/solar.dm
+++ b/code/modules/power/solar.dm
@@ -191,12 +191,12 @@
// Give back the glass type we were supplied with
/obj/item/solar_assembly/proc/give_glass(device_broken)
+ var/atom/Tsec = drop_location()
if(device_broken)
- new /obj/item/shard(loc)
- new /obj/item/shard(loc)
+ new /obj/item/shard(Tsec)
+ new /obj/item/shard(Tsec)
else if(glass_type)
- var/obj/item/stack/sheet/S = new glass_type(loc)
- S.amount = 2
+ new glass_type(Tsec, 2)
glass_type = null
diff --git a/code/modules/reagents/chemistry/reagents/other_reagents.dm b/code/modules/reagents/chemistry/reagents/other_reagents.dm
index 6a57ff0c18..81d55830d2 100644
--- a/code/modules/reagents/chemistry/reagents/other_reagents.dm
+++ b/code/modules/reagents/chemistry/reagents/other_reagents.dm
@@ -171,8 +171,7 @@
else if(istype(O, /obj/item/stack/sheet/hairlesshide))
var/obj/item/stack/sheet/hairlesshide/HH = O
- var/obj/item/stack/sheet/wetleather/WL = new(get_turf(HH))
- WL.amount = HH.amount
+ new /obj/item/stack/sheet/wetleather(get_turf(HH), HH.amount)
qdel(HH)
/*
diff --git a/code/modules/research/xenobiology/crossbreeding/_status_effects.dm b/code/modules/research/xenobiology/crossbreeding/_status_effects.dm
index ddbfdb8471..1c8e9ac350 100644
--- a/code/modules/research/xenobiology/crossbreeding/_status_effects.dm
+++ b/code/modules/research/xenobiology/crossbreeding/_status_effects.dm
@@ -448,8 +448,7 @@ datum/status_effect/stabilized/blue/on_remove()
else if(istype(O, /obj/item/stack/sheet/hairlesshide))
to_chat(owner, "[linked_extract] kept your hands wet! It wets [O]!")
var/obj/item/stack/sheet/hairlesshide/HH = O
- var/obj/item/stack/sheet/wetleather/WL = new(get_turf(HH))
- WL.amount = HH.amount
+ new /obj/item/stack/sheet/wetleather(get_turf(HH), HH.amount)
qdel(HH)
..()
diff --git a/code/modules/research/xenobiology/crossbreeding/charged.dm b/code/modules/research/xenobiology/crossbreeding/charged.dm
index 68aff64ee9..18b4e81398 100644
--- a/code/modules/research/xenobiology/crossbreeding/charged.dm
+++ b/code/modules/research/xenobiology/crossbreeding/charged.dm
@@ -66,10 +66,8 @@ Charged extracts:
colour = "metal"
/obj/item/slimecross/charged/metal/do_effect(mob/user)
- var/obj/item/stack/sheet/metal/M = new(get_turf(user))
- M.amount = 25
- var/obj/item/stack/sheet/plasteel/P = new(get_turf(user))
- P.amount = 10
+ new /obj/item/stack/sheet/metal(get_turf(user), 25)
+ new /obj/item/stack/sheet/plasteel(get_turf(user), 10)
user.visible_message("[src] grows into a plethora of metals!")
..()
@@ -85,8 +83,7 @@ Charged extracts:
colour = "dark purple"
/obj/item/slimecross/charged/darkpurple/do_effect(mob/user)
- var/obj/item/stack/sheet/mineral/plasma/M = new(get_turf(user))
- M.amount = 10
+ new /obj/item/stack/sheet/mineral/plasma(get_turf(user), 10)
user.visible_message("[src] produces a large amount of plasma!")
..()
@@ -113,8 +110,7 @@ Charged extracts:
colour = "bluespace"
/obj/item/slimecross/charged/bluespace/do_effect(mob/user)
- var/obj/item/stack/sheet/bluespace_crystal/M = new(get_turf(user))
- M.amount = 10
+ new /obj/item/stack/sheet/bluespace_crystal(get_turf(user), 10)
user.visible_message("[src] produces several sheets of polycrystal!")
..()
@@ -138,8 +134,7 @@ Charged extracts:
colour = "pyrite"
/obj/item/slimecross/charged/pyrite/do_effect(mob/user)
- var/obj/item/stack/sheet/mineral/bananium/M = new(get_turf(user))
- M.amount = 10
+ new /obj/item/stack/sheet/mineral/bananium(get_turf(user), 10)
user.visible_message("[src] solidifies with a horrifying banana stench!")
..()
diff --git a/code/modules/research/xenobiology/crossbreeding/industrial.dm b/code/modules/research/xenobiology/crossbreeding/industrial.dm
index 2503219e83..95f87ede0a 100644
--- a/code/modules/research/xenobiology/crossbreeding/industrial.dm
+++ b/code/modules/research/xenobiology/crossbreeding/industrial.dm
@@ -75,12 +75,7 @@ Industrial extracts:
/obj/item/slimecross/industrial/metal
colour = "metal"
plasmarequired = 3
- itempath = /obj/item/stack/sheet/metal
-
-/obj/item/slimecross/industrial/metal/do_after_spawn(obj/item/spawned)
- var/obj/item/stack/sheet/metal/M = spawned
- if(istype(M))
- M.amount = 10
+ itempath = /obj/item/stack/sheet/metal/ten
/obj/item/slimecross/industrial/yellow
colour = "yellow"