From af826713e42adb5ab92ea9a6016f85b2a2dddc7e Mon Sep 17 00:00:00 2001 From: Jack Fox <35575261+DubiousDoggo@users.noreply.github.com> Date: Thu, 24 Feb 2022 09:05:10 -0600 Subject: [PATCH] Atmos Pipe Crafting (#6737) --- .../Structures/Piping/Atmospherics/binary.yml | 18 ++ .../Structures/Piping/Atmospherics/pipes.yml | 15 ++ .../Piping/Atmospherics/trinary.yml | 6 + .../Structures/Piping/Atmospherics/unary.yml | 15 +- .../Graphs/utilities/atmos_binary.yml | 108 +++++++++ .../Graphs/utilities/atmos_pipes.yml | 91 +++++++ .../Graphs/utilities/atmos_trinary.yml | 40 ++++ .../Graphs/utilities/atmos_unary.yml | 75 ++++++ .../Recipes/Construction/utilities.yml | 226 ++++++++++++++++++ 9 files changed, 593 insertions(+), 1 deletion(-) create mode 100644 Resources/Prototypes/Recipes/Construction/Graphs/utilities/atmos_binary.yml create mode 100644 Resources/Prototypes/Recipes/Construction/Graphs/utilities/atmos_pipes.yml create mode 100644 Resources/Prototypes/Recipes/Construction/Graphs/utilities/atmos_trinary.yml create mode 100644 Resources/Prototypes/Recipes/Construction/Graphs/utilities/atmos_unary.yml diff --git a/Resources/Prototypes/Entities/Structures/Piping/Atmospherics/binary.yml b/Resources/Prototypes/Entities/Structures/Piping/Atmospherics/binary.yml index 281f1d3031..ae94ae512f 100644 --- a/Resources/Prototypes/Entities/Structures/Piping/Atmospherics/binary.yml +++ b/Resources/Prototypes/Entities/Structures/Piping/Atmospherics/binary.yml @@ -47,6 +47,9 @@ interfaces: - key: enum.GasPressurePumpUiKey.Key type: GasPressurePumpBoundUserInterface + - type: Construction + graph: GasBinary + node: pressurepump - type: entity parent: GasBinaryBase @@ -73,6 +76,9 @@ interfaces: - key: enum.GasVolumePumpUiKey.Key type: GasVolumePumpBoundUserInterface + - type: Construction + graph: GasBinary + node: volumepump - type: entity parent: GasBinaryBase @@ -95,6 +101,9 @@ visuals: - type: PipeColorVisualizer - type: GasPassiveGate + - type: Construction + graph: GasBinary + node: passivegate - type: entity parent: GasBinaryBase @@ -133,6 +142,9 @@ nodeGroupID: Pipe pipeDirection: South volume: 100 + - type: Construction + graph: GasBinary + node: valve - type: entity parent: GasBinaryBase @@ -161,6 +173,9 @@ !type:PortPipeNode nodeGroupID: Pipe pipeDirection: South + - type: Construction + graph: GasBinary + node: port - type: entity parent: GasUnaryBase @@ -185,3 +200,6 @@ - type: PipeColorVisualizer - type: VentPumpVisualizer - type: GasVentPump + - type: Construction + graph: GasBinary + node: dualportventpump diff --git a/Resources/Prototypes/Entities/Structures/Piping/Atmospherics/pipes.yml b/Resources/Prototypes/Entities/Structures/Piping/Atmospherics/pipes.yml index 6442ef021b..470a3723f7 100644 --- a/Resources/Prototypes/Entities/Structures/Piping/Atmospherics/pipes.yml +++ b/Resources/Prototypes/Entities/Structures/Piping/Atmospherics/pipes.yml @@ -83,6 +83,9 @@ layers: - state: pipeHalf map: [ "enum.PipeColorVisualizer+Layers.Pipe" ] + - type: Construction + graph: GasPipe + node: half - type: entity parent: GasPipeBase @@ -99,6 +102,9 @@ layers: - state: pipeStraight map: [ "enum.PipeColorVisualizer+Layers.Pipe" ] + - type: Construction + graph: GasPipe + node: straight - type: entity parent: GasPipeBase @@ -115,6 +121,9 @@ layers: - state: pipeBend map: [ "enum.PipeColorVisualizer+Layers.Pipe" ] + - type: Construction + graph: GasPipe + node: bend - type: entity parent: GasPipeBase @@ -131,6 +140,9 @@ layers: - state: pipeTJunction map: [ "enum.PipeColorVisualizer+Layers.Pipe" ] + - type: Construction + graph: GasPipe + node: tjunction - type: entity parent: GasPipeBase @@ -149,3 +161,6 @@ layers: - state: pipeFourway map: [ "enum.PipeColorVisualizer+Layers.Pipe" ] + - type: Construction + graph: GasPipe + node: fourway diff --git a/Resources/Prototypes/Entities/Structures/Piping/Atmospherics/trinary.yml b/Resources/Prototypes/Entities/Structures/Piping/Atmospherics/trinary.yml index 329596dda9..1d9a8dcd21 100644 --- a/Resources/Prototypes/Entities/Structures/Piping/Atmospherics/trinary.yml +++ b/Resources/Prototypes/Entities/Structures/Piping/Atmospherics/trinary.yml @@ -55,6 +55,9 @@ - type: GasFilter - type: Flippable mirrorEntity: GasFilterFlipped + - type: Construction + graph: GasTrinary + node: filter - type: entity parent: GasFilter @@ -130,6 +133,9 @@ inletTwo: filter - type: Flippable mirrorEntity: GasMixerFlipped + - type: Construction + graph: GasTrinary + node: mixer - type: entity parent: GasMixer diff --git a/Resources/Prototypes/Entities/Structures/Piping/Atmospherics/unary.yml b/Resources/Prototypes/Entities/Structures/Piping/Atmospherics/unary.yml index 09fa30a05b..1a0a1c8c45 100644 --- a/Resources/Prototypes/Entities/Structures/Piping/Atmospherics/unary.yml +++ b/Resources/Prototypes/Entities/Structures/Piping/Atmospherics/unary.yml @@ -47,6 +47,9 @@ - type: PipeColorVisualizer - type: VentPumpVisualizer - type: GasVentPump + - type: Construction + graph: GasUnary + node: ventpump - type: entity parent: GasUnaryBase @@ -71,6 +74,9 @@ visuals: - type: PipeColorVisualizer - type: GasPassiveVent + - type: Construction + graph: GasUnary + node: passivevent - type: entity parent: GasUnaryBase @@ -105,6 +111,9 @@ - type: ScrubberVisualizer - type: AtmosDevice - type: GasVentScrubber + - type: Construction + graph: GasUnary + node: ventscrubber - type: entity parent: GasUnaryBase @@ -127,12 +136,14 @@ visuals: - type: PipeColorVisualizer - type: GasOutletInjector + - type: Construction + graph: GasUnary + node: outletinjector - type: entity parent: BaseMachinePowered id: BaseGasThermoMachine name: thermomachine - description: Heats or cools gas in connected pipes. abstract: true placement: mode: SnapgridCenter @@ -172,6 +183,7 @@ parent: BaseGasThermoMachine id: GasThermoMachineFreezer name: freezer + description: Cools gas in connected pipes. placement: mode: SnapgridCenter components: @@ -197,6 +209,7 @@ parent: BaseGasThermoMachine id: GasThermoMachineHeater name: heater + description: Heats gas in connected pipes. placement: mode: SnapgridCenter components: diff --git a/Resources/Prototypes/Recipes/Construction/Graphs/utilities/atmos_binary.yml b/Resources/Prototypes/Recipes/Construction/Graphs/utilities/atmos_binary.yml new file mode 100644 index 0000000000..df6095b298 --- /dev/null +++ b/Resources/Prototypes/Recipes/Construction/Graphs/utilities/atmos_binary.yml @@ -0,0 +1,108 @@ +- type: constructionGraph + id: GasBinary + start: start + graph: + - node: start + edges: + - to: pressurepump + steps: + - material: Steel + amount: 2 + doAfter: 1 + - to: volumepump + steps: + - material: Steel + amount: 2 + doAfter: 1 + - to: passivegate + steps: + - material: Steel + amount: 2 + doAfter: 1 + - to: valve + steps: + - material: Steel + amount: 2 + doAfter: 1 + - to: port + steps: + - material: Steel + amount: 2 + doAfter: 1 + - to: dualportventpump + steps: + - material: Steel + amount: 2 + doAfter: 1 + - node: pressurepump + entity: GasPressurePump + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 + - node: volumepump + entity: GasVolumePump + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 + - node: passivegate + entity: GasPassiveGate + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 + - node: valve + entity: GasValve + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 + - node: port + entity: GasPort + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 + - node: dualportventpump + entity: GasDualPortVentPump + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 diff --git a/Resources/Prototypes/Recipes/Construction/Graphs/utilities/atmos_pipes.yml b/Resources/Prototypes/Recipes/Construction/Graphs/utilities/atmos_pipes.yml new file mode 100644 index 0000000000..a7819162c3 --- /dev/null +++ b/Resources/Prototypes/Recipes/Construction/Graphs/utilities/atmos_pipes.yml @@ -0,0 +1,91 @@ +- type: constructionGraph + id: GasPipe + start: start + graph: + - node: start + edges: + - to: half + steps: + - material: Steel + amount: 2 + doAfter: 1 + - to: straight + steps: + - material: Steel + amount: 2 + doAfter: 1 + - to: bend + steps: + - material: Steel + amount: 2 + doAfter: 1 + - to: tjunction + steps: + - material: Steel + amount: 2 + doAfter: 1 + - to: fourway + steps: + - material: Steel + amount: 2 + doAfter: 1 + - node: half + entity: GasPipeHalf + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 + - node: straight + entity: GasPipeStraight + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 + - node: bend + entity: GasPipeBend + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 + - node: tjunction + entity: GasPipeTJunction + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 + - node: fourway + entity: GasPipeFourway + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 \ No newline at end of file diff --git a/Resources/Prototypes/Recipes/Construction/Graphs/utilities/atmos_trinary.yml b/Resources/Prototypes/Recipes/Construction/Graphs/utilities/atmos_trinary.yml new file mode 100644 index 0000000000..eeace4b95f --- /dev/null +++ b/Resources/Prototypes/Recipes/Construction/Graphs/utilities/atmos_trinary.yml @@ -0,0 +1,40 @@ +- type: constructionGraph + id: GasTrinary + start: start + graph: + - node: start + edges: + - to: filter + steps: + - material: Steel + amount: 2 + doAfter: 1 + - to: mixer + steps: + - material: Steel + amount: 2 + doAfter: 1 + - node: filter + entity: GasFilter + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 + - node: mixer + entity: GasMixer + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 \ No newline at end of file diff --git a/Resources/Prototypes/Recipes/Construction/Graphs/utilities/atmos_unary.yml b/Resources/Prototypes/Recipes/Construction/Graphs/utilities/atmos_unary.yml new file mode 100644 index 0000000000..ca817712ab --- /dev/null +++ b/Resources/Prototypes/Recipes/Construction/Graphs/utilities/atmos_unary.yml @@ -0,0 +1,75 @@ +- type: constructionGraph + id: GasUnary + start: start + graph: + - node: start + edges: + - to: ventpump + steps: + - material: Steel + amount: 2 + doAfter: 1 + - to: passivevent + steps: + - material: Steel + amount: 2 + doAfter: 1 + - to: ventscrubber + steps: + - material: Steel + amount: 2 + doAfter: 1 + - to: outletinjector + steps: + - material: Steel + amount: 2 + doAfter: 1 + - node: ventpump + entity: GasVentPump + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 + - node: passivevent + entity: GasPassiveVent + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 + - node: ventscrubber + entity: GasVentScrubber + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 + - node: outletinjector + entity: GasOutletInjector + edges: + - to: start + completed: + - !type:SpawnPrototype + prototype: SheetSteel1 + amount: 2 + - !type:DeleteEntity + steps: + - tool: Welding + doAfter: 1 + \ No newline at end of file diff --git a/Resources/Prototypes/Recipes/Construction/utilities.yml b/Resources/Prototypes/Recipes/Construction/utilities.yml index 5b04376db3..ea49d81b8b 100644 --- a/Resources/Prototypes/Recipes/Construction/utilities.yml +++ b/Resources/Prototypes/Recipes/Construction/utilities.yml @@ -188,3 +188,229 @@ canBuildInImpassable: true conditions: - !type:WallmountCondition {} + +# ATMOS PIPES +- type: construction + name: gas pipe half + id: GasPipeHalf + graph: GasPipe + startNode: start + targetNode: half + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/pipe.rsi + state: pipeHalf + +- type: construction + name: gas pipe straight + id: GasPipeStraight + graph: GasPipe + startNode: start + targetNode: straight + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/pipe.rsi + state: pipeStraight + +- type: construction + name: gas pipe bend + id: GasPipeBend + graph: GasPipe + startNode: start + targetNode: bend + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/pipe.rsi + state: pipeBend + +- type: construction + name: gas pipe T junction + id: GasPipeTJunction + graph: GasPipe + startNode: start + targetNode: tjunction + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/pipe.rsi + state: pipeTJunction + +- type: construction + name: gas pipe fourway + id: GasPipeFourway + graph: GasPipe + startNode: start + targetNode: fourway + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/pipe.rsi + state: pipeFourway + +# ATMOS UNARY +- type: construction + name: air vent + id: GasVentPump + graph: GasUnary + startNode: start + targetNode: ventpump + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/vent.rsi + state: vent_off + +- type: construction + name: passive vent + id: GasPassiveVent + graph: GasUnary + startNode: start + targetNode: passivevent + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/vent.rsi + state: vent_off + +- type: construction + name: air scrubber + id: GasVentScrubber + graph: GasUnary + startNode: start + targetNode: ventscrubber + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/scrubber.rsi + state: scrub_off + +- type: construction + name: air injector + id: GasOutletInjector + graph: GasUnary + startNode: start + targetNode: outletinjector + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/pipe.rsi + state: pipeHalf + +# ATMOS BINARY +- type: construction + name: gas pump + id: GasPressurePump + graph: GasBinary + startNode: start + targetNode: pressurepump + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/pump.rsi + state: pumpPressure + +- type: construction + name: volumetric gas pump + id: GasVolumePump + graph: GasBinary + startNode: start + targetNode: volumepump + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/pump.rsi + state: pumpVolume + +- type: construction + id: GasPassiveGate + name: passive gate + graph: GasBinary + startNode: start + targetNode: passivegate + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/pump.rsi + state: pumpPassiveGate + +- type: construction + id: GasValve + name: manual valve + graph: GasBinary + startNode: start + targetNode: valve + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/pump.rsi + state: pumpManualValve + +- type: construction + id: GasPort + name: connector port + graph: GasBinary + startNode: start + targetNode: port + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/gascanisterport.rsi + state: gasCanisterPort + +- type: construction + id: GasDualPortVentPump + name: dual-port air vent + graph: GasBinary + startNode: start + targetNode: dualportventpump + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/vent.rsi + state: vent_off + +# ATMOS TRINARY +- type: construction + id: GasFilter + name: gas filter + graph: GasTrinary + startNode: start + targetNode: filter + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/gasfilter.rsi + state: gasFilter + +- type: construction + id: GasMixer + name: gas mixer + graph: GasTrinary + startNode: start + targetNode: mixer + category: Utilities + placementMode: SnapgridCenter + canBuildInImpassable: false + icon: + sprite: Structures/Piping/Atmospherics/gasmixer.rsi + state: gasMixer +