- type: entity
  id: Window
  parent: BaseConstructible
  name: window
  description: Don't smudge up the glass down there.
  placement:
    mode: SnapgridCenter
    snap:
    - Window
  components:
  - type: RCDDeconstructWhitelist
  - type: InteractionOutline
  - type: Sprite
    color: "#DDDDDD"
    netsync: false
    drawdepth: WallTops
    sprite: Constructible/Structures/Windows/window.rsi
  - type: Icon
    sprite: Constructible/Structures/Windows/window.rsi
    state: full
  - type: Physics
    bodyType: Static
    fixtures:
    - shape:
        !type:PhysShapeAabb {}
      layer:
      - Impassable
      - MobImpassable
      - VaultImpassable
      - SmallImpassable
      mask:
      - VaultImpassable
  - type: Damageable
    resistances: metallicResistances
  - type: Repairable
  - type: Destructible
    thresholds:
    - trigger:
        !type:DamageTrigger
        damage: 15
      behaviors:
      - !type:PlaySoundCollectionBehavior
        soundCollection: GlassBreak
      - !type:SpawnEntitiesBehavior
        spawn:
          ShardGlass:
            min: 1
            max: 2
      - !type:DoActsBehavior
        acts: [ "Destruction" ]
  - type: Airtight
  - type: Window
    base: window
  - type: Construction
    graph: window
    node: window
  - type: Appearance
    visuals:
    - type: WindowVisualizer

- type: entity
  id: ReinforcedWindow
  name: reinforced window
  parent: Window
  components:
  - type: Sprite
    drawdepth: WallTops
    sprite: Constructible/Structures/Windows/reinforced_window.rsi
  - type: Icon
    sprite: Constructible/Structures/Windows/reinforced_window.rsi
  - type: Repairable
    fuelCost: 10
    doAfterDelay: 2
  - type: Destructible
    thresholds:
    - trigger:
        !type:DamageTrigger
        damage: 75
      behaviors:
      - !type:PlaySoundCollectionBehavior
        soundCollection: GlassBreak
      - !type:SpawnEntitiesBehavior
        spawn:
          ShardGlassReinforced:
            min: 1
            max: 2
      - !type:DoActsBehavior
        acts: [ "Destruction" ]
  - type: Window
    base: rwindow
  - type: Construction
    graph: window
    node: reinforcedWindow

- type: entity
  id: PlasmaWindow
  name: plasma window
  parent: Window
  components:
  - type: Sprite
    drawdepth: WallTops
    sprite: Constructible/Structures/Windows/plasma_window.rsi
  - type: Icon
    sprite: Constructible/Structures/Windows/plasma_window.rsi
  - type: Damageable
    resistances: metallicResistances
  - type: Destructible
    thresholds:
    - trigger:
        !type:DamageTrigger
        damage: 100
      behaviors:
      - !type:PlaySoundCollectionBehavior
        soundCollection: GlassBreak
      - !type:SpawnEntitiesBehavior
        spawn:
          ShardGlassPlasma:
            min: 1
            max: 2
      - !type:DoActsBehavior
        acts: [ "Destruction" ]
    resistances: metallicResistances
  - type: Window
    base: pwindow
  - type: Construction
    graph: window
    node: plasmaWindow
