# SPDX-FileCopyrightText: 2024 ErhardSteinhauer
# SPDX-FileCopyrightText: 2025 Dvir
# SPDX-FileCopyrightText: 2025 SarahRaven
#
# SPDX-License-Identifier: AGPL-3.0-or-later

- type: entity
  parent: BaseStorageItem
  id: ConstructionBag
  name: construction bag
  description: A robust bag for construction specialists and engineers alike to carry large amounts of construction materials. Magnetises any nearby construction materials when attached to a belt.
  components:
  - type: MagnetPickup
  - type: Sprite
    sprite: _NF/Objects/Specific/Engineering/construction_bag.rsi
    layers:
    - state: icon
    - state: icon-on
      shader: unshaded
      visible: false
      map: [ "enum.ToggleableVisuals.Layer" ]
  - type: Appearance
  - type: GenericVisualizer
    visuals:
      enum.ToggleableVisuals.Enabled:
        enum.ToggleableVisuals.Layer:
          True: { visible: true }
          False: { visible: false }
  - type: Clothing
    sprite: _NF/Objects/Specific/Engineering/construction_bag.rsi
    quickEquip: false
    slots:
    - belt
  - type: Item
    size: Ginormous
    inhandVisuals:
      left:
      - state: inhand-left
        shader: unshaded
      right:
      - state: inhand-right
        shader: unshaded
  - type: Storage
    maxItemSize: Normal
    grid:
    - 0,0,9,3
    quickInsert: true
    areaInsert: true
    whitelist:
      tags:
      - Sheet
      - CableCoil
      - RawMaterial
      - PartBase
  - type: Dumpable
  - type: ItemToggle
    soundActivate:
      collection: sparks
      params:
        variation: 0.250
    soundDeactivate:
      collection: sparks
      params:
        variation: 0.250

- type: entity
  parent: ConstructionBag
  id: ConstructionBagOfHolding
  name: construction bag of holding
  description: A robust bag of holding for rich construction specialists and engineers alike to carry large amounts of construction materials. Magnetises any nearby construction materials when attached to a belt.
  components:
    - type: MagnetPickup
      range: 2
    - type: Sprite
      sprite: _NF/Objects/Specific/Engineering/construction_bag.rsi
      layers:
        - state: icon
        - state: icon-bluespace-overlay
        - state: icon-bluespace-overlay-unshaded
          shader: unshaded
        - state: icon-on-bluespace
          visible: false
          map: [ "enum.ToggleableVisuals.Layer" ]
    - type: Item
      size: Huge
      inhandVisuals:
        left:
          - state: inhand-left
          - state: inhand-left-bluespace-overlay
          - state: inhand-left-bluespace-overlay-unshaded
            shader: unshaded
        right:
          - state: inhand-right
          - state: inhand-right-bluespace-overlay
          - state: inhand-right-bluespace-overlay-unshaded
            shader: unshaded
    - type: Clothing
      sprite: _NF/Objects/Specific/Engineering/construction_bag.rsi
      quickEquip: false
      slots:
        - belt
      clothingVisuals:
        belt:
          - state: equipped-BELT
          - state: equipped-BELT-bluespace-overlay
          - state: equipped-BELT-bluespace-overlay-unshaded
            shader: unshaded
    - type: Storage
      grid:
        - 0,0,19,9
    - type: PhysicalComposition
      materialComposition:
        Steel: 250
        Plastic: 100
        Plasma: 100
        Uranium: 100
        BSCrystal: 20
