diff --git a/code/game/machinery/doors/airlock.dm b/code/game/machinery/doors/airlock.dm index dda0fd7ad06..26bd957f341 100644 --- a/code/game/machinery/doors/airlock.dm +++ b/code/game/machinery/doors/airlock.dm @@ -81,7 +81,6 @@ GLOBAL_LIST_EMPTY(airlock_emissive_underlays) var/obj/item/airlock_electronics/electronics var/shockCooldown = FALSE //Prevents multiple shocks from happening var/obj/item/note //Any papers pinned to the airlock - var/previous_airlock = /obj/structure/door_assembly //what airlock assembly mineral plating was applied to var/airlock_material //material of inner filling; if its an airlock with glass, this should be set to "glass" var/overlays_file = 'icons/obj/doors/airlocks/station/overlays.dmi' var/note_overlay_file = 'icons/obj/doors/airlocks/station/overlays.dmi' //Used for papers and photos pinned to the airlock @@ -1460,7 +1459,6 @@ GLOBAL_LIST_EMPTY(airlock_emissive_underlays) DA.polarized_glass = polarized_glass DA.state = AIRLOCK_ASSEMBLY_NEEDS_ELECTRONICS DA.created_name = name - DA.previous_assembly = previous_airlock DA.update_name() DA.update_icon() diff --git a/code/game/objects/items/stacks/sheets/mineral.dm b/code/game/objects/items/stacks/sheets/mineral.dm index c3f2112cce2..bbde6b90072 100644 --- a/code/game/objects/items/stacks/sheets/mineral.dm +++ b/code/game/objects/items/stacks/sheets/mineral.dm @@ -18,6 +18,7 @@ Mineral Sheets GLOBAL_LIST_INIT(sandstone_recipes, list ( new /datum/stack_recipe("pile of dirt", /obj/machinery/hydroponics/soil, 3, time = 10, one_per_turf = TRUE, on_floor = TRUE), new /datum/stack_recipe("sandstone door", /obj/structure/mineral_door/sandstone, 10, one_per_turf = TRUE, on_floor = TRUE), + new /datum/stack_recipe("sandstone airlock assembly", /obj/structure/door_assembly/door_assembly_sandstone, 4, time = 50, one_per_turf = TRUE, on_floor = TRUE), null, new /datum/stack_recipe("Assistant Statue", /obj/structure/statue/sandstone/assistant, 5, one_per_turf = TRUE, on_floor = TRUE), null, @@ -26,6 +27,7 @@ GLOBAL_LIST_INIT(sandstone_recipes, list ( GLOBAL_LIST_INIT(silver_recipes, list ( new /datum/stack_recipe("silver door", /obj/structure/mineral_door/silver, 10, one_per_turf = TRUE, on_floor = TRUE), + new /datum/stack_recipe("silver airlock assembly", /obj/structure/door_assembly/door_assembly_silver, 4, time = 50, one_per_turf = TRUE, on_floor = TRUE), null, new /datum/stack_recipe("silver tile", /obj/item/stack/tile/mineral/silver, 1, 4, 20), null, @@ -40,6 +42,7 @@ GLOBAL_LIST_INIT(silver_recipes, list ( GLOBAL_LIST_INIT(diamond_recipes, list ( new /datum/stack_recipe("diamond door", /obj/structure/mineral_door/transparent/diamond, 10, one_per_turf = TRUE, on_floor = TRUE), + new /datum/stack_recipe("diamond airlock assembly", /obj/structure/door_assembly/door_assembly_diamond, 4, time = 50, one_per_turf = TRUE, on_floor = TRUE), null, new /datum/stack_recipe("diamond tile", /obj/item/stack/tile/mineral/diamond, 1, 4, 20), null, @@ -52,6 +55,7 @@ GLOBAL_LIST_INIT(diamond_recipes, list ( GLOBAL_LIST_INIT(uranium_recipes, list ( new /datum/stack_recipe("uranium door", /obj/structure/mineral_door/uranium, 10, one_per_turf = TRUE, on_floor = TRUE), + new /datum/stack_recipe("uranium airlock assembly", /obj/structure/door_assembly/door_assembly_uranium, 4, time = 50, one_per_turf = TRUE, on_floor = TRUE), null, new /datum/stack_recipe("uranium tile", /obj/item/stack/tile/mineral/uranium, 1, 4, 20), null, @@ -63,6 +67,7 @@ GLOBAL_LIST_INIT(uranium_recipes, list ( GLOBAL_LIST_INIT(gold_recipes, list ( new /datum/stack_recipe("golden door", /obj/structure/mineral_door/gold, 10, one_per_turf = TRUE, on_floor = TRUE), + new /datum/stack_recipe("golden airlock assembly", /obj/structure/door_assembly/door_assembly_gold, 4, time = 50, one_per_turf = TRUE, on_floor = TRUE), null, new /datum/stack_recipe("gold tile", /obj/item/stack/tile/mineral/gold, 1, 4, 20), null, @@ -79,6 +84,7 @@ GLOBAL_LIST_INIT(gold_recipes, list ( GLOBAL_LIST_INIT(plasma_recipes, list ( new /datum/stack_recipe/dangerous("plasma door", /obj/structure/mineral_door/transparent/plasma, 10, one_per_turf = TRUE, on_floor = TRUE), + new /datum/stack_recipe/dangerous("plasma airlock assembly", /obj/structure/door_assembly/door_assembly_plasma, 4, time = 50, one_per_turf = TRUE, on_floor = TRUE), null, new /datum/stack_recipe/dangerous("plasma tile", /obj/item/stack/tile/mineral/plasma, 1, 4, 20), null, @@ -89,6 +95,8 @@ GLOBAL_LIST_INIT(plasma_recipes, list ( )) GLOBAL_LIST_INIT(bananium_recipes, list ( + new /datum/stack_recipe("bananium airlock assembly", /obj/structure/door_assembly/door_assembly_bananium, 4, time = 50, one_per_turf = TRUE, on_floor = TRUE), + null, new /datum/stack_recipe("bananium tile", /obj/item/stack/tile/mineral/bananium, 1, 4, 20), null, new /datum/stack_recipe("Clown Statue", /obj/structure/statue/bananium/clown, 5, one_per_turf = TRUE, on_floor = TRUE), @@ -97,6 +105,8 @@ GLOBAL_LIST_INIT(bananium_recipes, list ( )) GLOBAL_LIST_INIT(tranquillite_recipes, list ( + new /datum/stack_recipe("tranquillite airlock assembly", /obj/structure/door_assembly/door_assembly_tranquillite, 4, time = 50, one_per_turf = TRUE, on_floor = TRUE), + null, new /datum/stack_recipe("invisible wall", /obj/structure/barricade/mime, 5, one_per_turf = TRUE, on_floor = TRUE, time = 50), null, new /datum/stack_recipe("silent tile", /obj/item/stack/tile/mineral/tranquillite, 1, 4, 20), @@ -348,6 +358,8 @@ GLOBAL_LIST_INIT(sandbag_recipes, list ( point_value = 20 GLOBAL_LIST_INIT(titanium_recipes, list( + new /datum/stack_recipe("titanium airlock assembly", /obj/structure/door_assembly/door_assembly_titanium, 4, time = 50, one_per_turf = TRUE, on_floor = TRUE), + null, new /datum/stack_recipe("titanium tile", /obj/item/stack/tile/mineral/titanium, 1, 4, 20), new /datum/stack_recipe("surgical tray", /obj/structure/table/tray, 2, one_per_turf = TRUE, on_floor = TRUE), )) diff --git a/code/game/objects/items/stacks/sheets/sheet_types.dm b/code/game/objects/items/stacks/sheets/sheet_types.dm index bebb6137375..5270b90bb36 100644 --- a/code/game/objects/items/stacks/sheets/sheet_types.dm +++ b/code/game/objects/items/stacks/sheets/sheet_types.dm @@ -207,6 +207,7 @@ GLOBAL_LIST_INIT(wood_recipes, list( new /datum/stack_recipe("dresser", /obj/structure/dresser, 30, time = 5 SECONDS, one_per_turf = TRUE, on_floor = TRUE), new /datum/stack_recipe("dog bed", /obj/structure/bed/dogbed, 10, time = 1 SECONDS, one_per_turf = TRUE, on_floor = TRUE), new /datum/stack_recipe("wooden door", /obj/structure/mineral_door/wood, 10, time = 2 SECONDS, one_per_turf = TRUE, on_floor = TRUE), + new /datum/stack_recipe("wooden airlock assembly", /obj/structure/door_assembly/door_assembly_wood, 4, time = 50, one_per_turf = TRUE, on_floor = TRUE), new /datum/stack_recipe("coffin", /obj/structure/closet/coffin, 5, time = 1.5 SECONDS, one_per_turf = TRUE, on_floor = TRUE), )), new /datum/stack_recipe_list("pews", list( @@ -241,6 +242,7 @@ GLOBAL_LIST_INIT(wood_recipes, list( resistance_flags = FLAMMABLE armor = list(MELEE = 0, BULLET = 0, LASER = 0, ENERGY = 0, BOMB = 0, BIO = 0, RAD = 0, FIRE = 50, ACID = 0) merge_type = /obj/item/stack/sheet/wood + sheettype = "wood" /obj/item/stack/sheet/wood/New(loc, amount=null) recipes = GLOB.wood_recipes diff --git a/code/game/objects/structures/door_assembly.dm b/code/game/objects/structures/door_assembly.dm index ba0b74b936b..fa0a9860652 100644 --- a/code/game/objects/structures/door_assembly.dm +++ b/code/game/objects/structures/door_assembly.dm @@ -7,8 +7,11 @@ max_integrity = 200 var/overlays_file = 'icons/obj/doors/airlocks/station/overlays.dmi' var/state = AIRLOCK_ASSEMBLY_NEEDS_WIRES + /// String value. Used in user chat messages var/mineral + /// mineral object path. var/mineral_type + var/base_name = "airlock" var/obj/item/airlock_electronics/electronics var/airlock_type = /obj/machinery/door/airlock //the type path of the airlock once completed @@ -17,7 +20,6 @@ var/polarized_glass = FALSE var/created_name var/heat_proof_finished = FALSE //whether to heat-proof the finished airlock - var/previous_assembly = /obj/structure/door_assembly var/noglass = FALSE //airlocks with no glass version, also cannot be modified with sheets var/material_type = /obj/item/stack/sheet/metal var/material_amt = 4 @@ -47,11 +49,7 @@ . += "The circuit is connected loosely to its slot, but the maintenance panel is unscrewed and open." if(glass) . += "The assembly has its electrochromic windows [polarized_glass ? "enabled" : "disabled"] and can be configured." - if(!mineral && !glass && !noglass) - . += "There is a small paper placard on the assembly[doorname]. There are empty slots for glass windows and mineral covers." - else if(!mineral && glass && !noglass) - . += "There is a small paper placard on the assembly[doorname]. There are empty slots for mineral covers." - else if(mineral && !glass && !noglass) + if(!glass && !noglass) . += "There is a small paper placard on the assembly[doorname]. There are empty slots for glass windows." else . += "There is a small paper placard on the assembly[doorname]." @@ -111,22 +109,6 @@ to_chat(user, "You install regular glass windows into the airlock assembly.") S.use(1) glass = TRUE - if(!mineral) - if(istype(S, /obj/item/stack/sheet/mineral) && S.sheettype) - var/M = S.sheettype - if(S.get_amount() >= 2) - playsound(loc, S.usesound, 100, 1) - user.visible_message("[user] adds [S.name] to the airlock assembly.", "You start to install [S.name] into the airlock assembly...") - if(do_after(user, 40 * S.toolspeed, target = src)) - if(S.get_amount() < 2 || mineral) - return - to_chat(user, "You install [M] plating into the airlock assembly.") - S.use(2) - var/mineralassembly = text2path("/obj/structure/door_assembly/door_assembly_[M]") - var/obj/structure/door_assembly/MA = new mineralassembly(loc) - transfer_assembly_vars(src, MA, TRUE) - else - to_chat(user, "You need at least two sheets to add a mineral cover!") else to_chat(user, "You cannot add [S] to [src]!") else @@ -187,7 +169,6 @@ door.name = created_name else door.name = base_name - door.previous_airlock = previous_assembly electronics.forceMove(door) electronics = null qdel(src) @@ -226,18 +207,7 @@ . = TRUE if(!I.tool_use_check(user, 0)) return - if(mineral) - var/obj/item/stack/sheet/mineral/mineral_path = text2path("/obj/item/stack/sheet/mineral/[mineral]") - user.visible_message("[user] welds the [mineral] plating off [src].",\ - "You start to weld the [mineral] plating off [src]...",\ - "You hear welding.") - if(!I.use_tool(src, user, 40, volume = I.tool_volume)) - return - to_chat(user, "You weld the [mineral] plating off.") - new mineral_path(loc, 2) - var/obj/structure/door_assembly/PA = new previous_assembly(loc) - transfer_assembly_vars(src, PA) - else if(glass) + if(glass) user.visible_message("[user] welds the glass panel out of [src].",\ "You start to weld the glass panel out of the [src]...",\ "You hear welding.") @@ -309,8 +279,6 @@ target.created_name = source.created_name target.state = source.state target.anchored = source.anchored - if(previous) - target.previous_assembly = source.type if(electronics) target.electronics = source.electronics source.electronics.forceMove(target) @@ -321,9 +289,14 @@ /obj/structure/door_assembly/deconstruct(disassembled = TRUE) if(!(flags & NODECONSTRUCT)) var/turf/T = get_turf(src) + var/to_spawn_type + if(mineral_type) + to_spawn_type = mineral_type + else + to_spawn_type = material_type if(!disassembled) material_amt = rand(2,4) - new material_type(T, material_amt) + new to_spawn_type(T, material_amt) if(glass) if(disassembled) if(heat_proof_finished) @@ -332,6 +305,4 @@ new /obj/item/stack/sheet/glass(T) else new /obj/item/shard(T) - if(mineral_type) - new mineral_type(T, 2) qdel(src)