]> git.smokeofanarchy.ru Git - space-station-14.git/commitdiff
Construction Blast door (#24050)
authorNim <128169402+Nimfar11@users.noreply.github.com>
Mon, 15 Jan 2024 12:49:08 +0000 (14:49 +0200)
committerGitHub <noreply@github.com>
Mon, 15 Jan 2024 12:49:08 +0000 (15:49 +0300)
* construction blast door

* fix

* price

* fix2

* hem

* xif

* Static

Resources/Prototypes/Entities/Structures/Doors/Shutter/blast_door.yml
Resources/Prototypes/Recipes/Construction/Graphs/structures/blast_door.yml [new file with mode: 0644]
Resources/Prototypes/Recipes/Construction/structures.yml
Resources/Textures/Structures/Doors/Shutters/blastdoor.rsi/assembly.png [new file with mode: 0644]
Resources/Textures/Structures/Doors/Shutters/blastdoor.rsi/meta.json

index 1673ccd0cb2c93d9d801a73899452190a461ecab..97f3c1b9e30013897ccd53a0e57ca88060a52483 100644 (file)
   - type: Damageable
     damageContainer: StructuralInorganic
     damageModifierSet: StrongMetallic
+  - type: ContainerFill
+    containers:
+      board: [ DoorElectronics ]
+  - type: Construction
+    graph: BlastDoor
+    node: blastdoor
+    containers:
+    - board
+  - type: StaticPrice
+    price: 280
 
 - type: entity
   id: BlastDoorOpen
     airBlocked: false
   - type: RadiationBlocker
     enabled: false
+
+- type: entity
+  id: BlastDoorFrame
+  parent: BaseStructureDynamic
+  name: blast door frame
+  description: This one says 'BLAST DONGER'.
+  components:
+  - type: Sprite
+    sprite: Structures/Doors/Shutters/blastdoor.rsi
+    state: assembly
+  - type: InteractionOutline
+  - type: Damageable
+    damageContainer: Inorganic
+    damageModifierSet: Metallic
+  - type: Destructible
+    thresholds:
+    - trigger:
+        !type:DamageTrigger
+        damage: 300
+      behaviors:
+      - !type:DoActsBehavior
+        acts: ["Destruction"]
+  - type: Physics
+    bodyType: Static
+  - type: Fixtures
+    fixtures:
+      fix1:
+        shape:
+          !type:PhysShapeAabb
+          bounds: "-0.45,-0.45,0.45,0.45"
+        density: 55
+        mask:
+        - Impassable
+        - HighImpassable
+        layer:
+        - HighImpassable
+  - type: Transform
+    noRot: true
+  - type: Construction
+    graph: BlastDoor
+    node: frame1
+  placement:
+    mode: SnapgridCenter
diff --git a/Resources/Prototypes/Recipes/Construction/Graphs/structures/blast_door.yml b/Resources/Prototypes/Recipes/Construction/Graphs/structures/blast_door.yml
new file mode 100644 (file)
index 0000000..ad84d83
--- /dev/null
@@ -0,0 +1,109 @@
+- type: constructionGraph
+  id: BlastDoor
+  start: start
+  graph:
+    - node: start
+      edges:
+        - to: frame1
+          completed:
+            - !type:SetAnchor
+              value: false
+          steps:
+            - material: Plasteel
+              amount: 10
+              doAfter: 3
+
+    - node: frame1
+      entity: BlastDoorFrame
+      actions:
+        - !type:SnapToGrid {}
+        - !type:SetAnchor {}
+      edges:
+        - to: frame2
+          conditions:
+            - !type:EntityAnchored {}
+          steps:
+            - material: Cable
+              amount: 5
+              doAfter: 2
+        - to: start
+          conditions:
+            - !type:EntityAnchored
+              anchored: false
+          completed:
+            - !type:SpawnPrototype
+              prototype: SheetPlasteel1
+              amount: 10
+            - !type:DeleteEntity {}
+          steps:
+            - tool: Welding
+              doAfter: 4
+
+    - node: frame2
+      edges:
+        - to: frame3
+          conditions:
+            - !type:EntityAnchored {}
+          steps:
+            - tag: DoorElectronics
+              store: board
+              name: Door Electronics
+              icon:
+                sprite: "Objects/Misc/module.rsi"
+                state: "door_electronics"
+              doAfter: 2
+        - to: frame1
+          completed:
+            - !type:SpawnPrototype
+              prototype: CableApcStack1
+              amount: 5
+          steps:
+            - tool: Cutting
+              doAfter: 4
+            - tool: Prying
+              doAfter: 2
+
+    - node: frame3
+      edges:
+        - to: frame4
+          conditions:
+            - !type:EntityAnchored {}
+          steps:
+            - tool: Screwing
+              doAfter: 2
+            - tool: Prying
+              doAfter: 3
+
+    - node: frame4
+      edges:
+        - to: blastdoor
+          conditions:
+            - !type:EntityAnchored {}
+          steps:
+            - tool: Anchoring
+              doAfter: 2
+        - to: frame2
+          conditions:
+            - !type:EntityAnchored {}
+          completed:
+            - !type:EmptyAllContainers
+              pickup: true
+              emptyAtUser: true
+          steps:
+            - tool: Screwing
+              doAfter: 4
+            - tool: Anchoring
+              doAfter: 3
+            - tool: Prying
+              doAfter: 3
+
+    - node: blastdoor
+      entity: BlastDoorOpen
+      edges:
+        - to: frame4
+          conditions:
+            - !type:DoorWelded
+              welded: true
+          steps:
+            - tool: Anchoring
+              doAfter: 2
index c9c7a8fe455ea8ab16b60cdef05011a7873dbd79..b9e3477f3cfdcaac39263cc0cc516fdc1f18ad87 100644 (file)
   conditions:
     - !type:TileNotBlocked
 
-
 - type: construction
   name: diagonal shuttle wall
   id: DiagonalShuttleWall
   placementMode: SnapgridCenter
   canBuildInImpassable: true
 
+- type: construction
+  name: blast door
+  id: BlastDoor
+  graph: BlastDoor
+  startNode: start
+  targetNode: blastdoor
+  category: construction-category-structures
+  description: This one says 'BLAST DONGER'.
+  icon:
+    sprite: Structures/Doors/Shutters/blastdoor.rsi
+    state: closed
+  objectType: Structure
+  placementMode: SnapgridCenter
+  canBuildInImpassable: true
+
 - type: construction
   name: catwalk
   id: Catwalk
diff --git a/Resources/Textures/Structures/Doors/Shutters/blastdoor.rsi/assembly.png b/Resources/Textures/Structures/Doors/Shutters/blastdoor.rsi/assembly.png
new file mode 100644 (file)
index 0000000..f52f0ec
Binary files /dev/null and b/Resources/Textures/Structures/Doors/Shutters/blastdoor.rsi/assembly.png differ
index a8d4b41fdd7d653fba36b67880a9a278ed105682..905fe8a64ebf163e13912e406e57332c78d9647b 100644 (file)
@@ -1 +1,50 @@
-{"name":1,"size":{"x":32,"y":32},"states":[{"name":"closing","directions":1,"delays":[[0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.4]]},{"name":"opening","directions":1,"delays":[[0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.4]]},{"name":"open","directions":1},{"name":"closed","directions":1}],"license":"CC-BY-SA-3.0","copyright":"Tgstation at 97b4295aca9f31a750456e40730d05b5837e39fc","version":1}
\ No newline at end of file
+{
+    "version": 1,
+    "license": "CC-BY-SA-3.0",
+    "copyright": "Tgstation at 97b4295aca9f31a750456e40730d05b5837e39fc",
+    "size": {
+        "x": 32,
+        "y": 32
+    },
+    "states": [
+        {
+            "name": "assembly"
+        },
+        {
+            "name": "closing",
+            "delays": [
+                [
+                    0.1,
+                    0.1,
+                    0.1,
+                    0.1,
+                    0.1,
+                    0.1,
+                    0.1,
+                    0.4
+                ]
+            ]
+        },
+        {
+            "name": "opening",
+            "delays": [
+                [
+                    0.1,
+                    0.1,
+                    0.1,
+                    0.1,
+                    0.1,
+                    0.1,
+                    0.1,
+                    0.4
+                ]
+            ]
+        },
+        {
+            "name": "open"
+        },
+        {
+            "name": "closed"
+        }
+    ]
+}