# SPDX-FileCopyrightText: 2022 EmoGarbage404 <98561806+EmoGarbage404@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 Fishfish458 <47410468+Fishfish458@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 Jacob Tong <10494922+ShadowCommander@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 fishfish458 <fishfish458>
# SPDX-FileCopyrightText: 2023 AJCM-git <60196617+AJCM-git@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 Emisse <99158783+Emisse@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 Nairod <110078045+Nairodian@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 lzk <124214523+lzk228@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Aiden <aiden@djkraz.com>
# SPDX-FileCopyrightText: 2024 Leon Friedrich <60421075+ElectroJr@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 MilenVolf <63782763+MilenVolf@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Nemanja <98561806+EmoGarbage404@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Vasilis <vasilis@pikachu.systems>
# SPDX-FileCopyrightText: 2024 Velcroboy <107660393+IamVelcroboy@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Velcroboy <velcroboy333@hotmail.com>
# SPDX-FileCopyrightText: 2025 Aiden <28298836+Aidenkrz@users.noreply.github.com>
#
# SPDX-License-Identifier: AGPL-3.0-or-later

- type: entity
  id: PlasticFlapsBase
  parent: BaseStructure
  abstract: true
  placement:
    mode: SnapgridCenter
  components:
  - type: Sprite
    sprite: Structures/plastic_flaps.rsi
    state: plasticflaps
    drawdepth: Mobs
  - type: Physics
    bodyType: Static
  - type: Transform
    anchored: true
  - type: Fixtures
    fixtures:
      fix1:
        shape:
          !type:PhysShapeAabb
          bounds: "-0.49,-0.49,0.49,0.49"
        density: 100
        mask:
        - Impassable
        layer:
        - MidImpassable
  - type: Damageable
    damageContainer: StructuralInorganic
    damageModifierSet: Metallic
  - type: Destructible
    thresholds:
    - trigger:
        !type:DamageTrigger
        damage: 100
      behaviors:
      - !type:DoActsBehavior
        acts: ["Destruction"]
  - type: StaticPrice
    price: 100

- type: entity
  id: PlasticFlapsClear
  parent: PlasticFlapsBase
  name: plastic flaps
  suffix: Clear
  description: Heavy duty, plastic flaps. Definitely can't get past those. No way.
  components:
  - type: Construction
    graph: PlasticFlapsGraph
    node: plasticFlaps

- type: entity
  id: PlasticFlapsOpaque
  parent: PlasticFlapsBase
  name: plastic flaps
  suffix: Opaque
  description: Heavy duty, plastic flaps. Definitely can't get past those. No way.
  components:
  - type: Fixtures
    fixtures:
      fix1:
        shape:
          !type:PhysShapeAabb
          bounds: "-0.49,-0.49,0.49,0.49"
        density: 100
        mask:
        - Impassable
        layer:
        - Opaque
        - MidImpassable
  - type: Occluder
  - type: Construction
    graph: PlasticFlapsGraph
    node: opaqueFlaps

- type: entity
  id: PlasticFlapsAirtightClear
  parent: PlasticFlapsBase
  name: airtight plastic flaps
  suffix: Airtight, Clear
  description: Heavy duty, slightly stronger, airtight plastic flaps. Definitely can't get past those. No way.
  components:
  - type: Destructible
    thresholds:
    - trigger:
        !type:DamageTrigger
        damage: 150
      behaviors:
      - !type:DoActsBehavior
        acts: ["Destruction"]
  - type: Airtight
  - type: StaticPrice
    price: 100

- type: entity
  id: PlasticFlapsAirtightOpaque
  parent: PlasticFlapsBase
  name: airtight plastic flaps
  suffix: Airtight, Opaque
  description: Heavy duty, slightly stronger, airtight plastic flaps. Definitely can't get past those. No way.
  components:
  - type: Destructible
    thresholds:
    - trigger:
        !type:DamageTrigger
        damage: 150
      behaviors:
      - !type:DoActsBehavior
        acts: ["Destruction"]
  - type: Airtight
  - type: StaticPrice
    price: 100