# SPDX-FileCopyrightText: 2020 AJCM-git <60196617+AJCM-git@users.noreply.github.com>
# SPDX-FileCopyrightText: 2020 ALMv1 <70581577+ALMv1@users.noreply.github.com>
# SPDX-FileCopyrightText: 2020 DrSmugleaf <DrSmugleaf@users.noreply.github.com>
# SPDX-FileCopyrightText: 2020 FrostMando <68990565+FrostMando@users.noreply.github.com>
# SPDX-FileCopyrightText: 2020 Paul Ritter <ritter.paul1@googlemail.com>
# SPDX-FileCopyrightText: 2020 Pieter-Jan Briers <pieterjan.briers+git@gmail.com>
# SPDX-FileCopyrightText: 2021 Galactic Chimp <GalacticChimpanzee@gmail.com>
# SPDX-FileCopyrightText: 2021 Metal Gear Sloth <metalgearsloth@gmail.com>
# SPDX-FileCopyrightText: 2021 PetMudstone <38266309+PetMudstone@users.noreply.github.com>
# SPDX-FileCopyrightText: 2021 Swept <sweptwastaken@protonmail.com>
# SPDX-FileCopyrightText: 2022 Emisse <99158783+Emisse@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 Fishfish458 <47410468+Fishfish458@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 Justin Trotter <trotter.justin@gmail.com>
# SPDX-FileCopyrightText: 2022 Leon Friedrich <60421075+ElectroJr@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 Morb <14136326+Morb0@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 Peptide90 <78795277+Peptide90@users.noreply.github.com>
# SPDX-FileCopyrightText: 2022 fishfish458 <fishfish458>
# SPDX-FileCopyrightText: 2022 metalgearsloth <comedian_vs_clown@hotmail.com>
# SPDX-FileCopyrightText: 2023 Jackal298 <129199891+Jackal298@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 Nairod <110078045+Nairodian@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 Puro <103608145+PuroSlavKing@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 RobbyTheFish <83671165+RobbyTheFish@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 brainfood1183 <113240905+brainfood1183@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 deltanedas <39013340+deltanedas@users.noreply.github.com>
# SPDX-FileCopyrightText: 2023 deltanedas <@deltanedas:kde.org>
# SPDX-FileCopyrightText: 2023 potato1234_x <79580518+potato1234x@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 21Melkuu <79728504+21Melkuu@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Aidenkrz <aiden@djkraz.com>
# SPDX-FileCopyrightText: 2024 BombasterDS <115770678+BombasterDS@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 EmoGarbage404 <retron404@gmail.com>
# SPDX-FileCopyrightText: 2024 IProduceWidgets <107586145+IProduceWidgets@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Kara <lunarautomaton6@gmail.com>
# SPDX-FileCopyrightText: 2024 Mr. 27 <45323883+Dutch-VanDerLinde@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Nemanja <98561806+EmoGarbage404@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 PoTeletubby <ajcraigaz@gmail.com>
# SPDX-FileCopyrightText: 2024 RedBookcase <Usualmoves@gmail.com>
# SPDX-FileCopyrightText: 2024 RedBookcase <crazykid1590@gmail.com>
# SPDX-FileCopyrightText: 2024 Teapug <159912420+Teapug@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 Winkarst <74284083+Winkarst-cpu@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 slarticodefast <161409025+slarticodefast@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 to4no_fix <156101927+chavonadelal@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Aiden <28298836+Aidenkrz@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Aiden <aiden@djkraz.com>
# SPDX-FileCopyrightText: 2025 BramvanZijp <56019239+BramvanZijp@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Fishbait <Fishbait@git.ml>
# SPDX-FileCopyrightText: 2025 GMWQ <garethquaile@gmail.com>
# SPDX-FileCopyrightText: 2025 Gareth Quaile <garethquaile@gmail.com>
# SPDX-FileCopyrightText: 2025 GoobBot <uristmchands@proton.me>
# SPDX-FileCopyrightText: 2025 Killerqu00 <47712032+Killerqu00@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 SX-7 <92227810+SX-7@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 SlamBamActionman <83650252+SlamBamActionman@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Solstice <solsticeofthewinter@gmail.com>
# SPDX-FileCopyrightText: 2025 SolsticeOfTheWinter <solsticeofthewinter@gmail.com>
# SPDX-FileCopyrightText: 2025 fishbait <gnesse@gmail.com>
#
# SPDX-License-Identifier: AGPL-3.0-or-later

- type: entity
  parent: [Clothing, ContentsExplosionResistanceBase]
  id: ClothingBackpack
  name: backpack
  description: You wear this on your back and put items into it.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/backpack.rsi
    state: icon
  - type: Item
    size: Huge
  - type: Clothing
    quickEquip: false
    slots:
    - back
  # Goobstation edit start
    equipSound:
      path: /Audio/_Goobstation/Items/handling/backpack_equip.ogg
      params:
        volume: -9
  - type: EmitSoundOnPickup
    sound:
      path: /Audio/_Goobstation/Items/handling/backpack_pickup.ogg
      params:
        volume: -9
  - type: EmitSoundOnDrop
    sound:
      path: /Audio/_Goobstation/Items/handling/backpack_drop.ogg
      params:
        volume: -11
  - type: EmitSoundOnLand
    sound:
      path: /Audio/_Goobstation/Items/handling/backpack_drop.ogg
      params:
        volume: -11
  # Goobstation edit end
  - type: Storage
    grid:
    - 0,0,6,3
    maxItemSize: Huge
  - type: ContainerContainer
    containers:
      storagebase: !type:Container
        ents: []
  - type: UserInterface
    interfaces:
      enum.StorageUiKey.Key:
        type: StorageBoundUserInterface
  # to prevent bag open/honk spam
  - type: UseDelay
    delay: 0.5
  - type: ExplosionResistance
    damageCoefficient: 0.9
  - type: Tag
    tags:
    - WhitelistChameleon
    - Backpack

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackClown
  name: giggles von honkerton
  description: It's a backpack made by Honk! Co.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/clown.rsi
  - type: Storage
    storageOpenSound:
      collection: BikeHorn

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackIan
  name: Ian's backpack
  description: Sometimes he wears it.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/ian.rsi
  - type: Storage
    storageOpenSound:
      collection: IanBark

- type: entity
  parent: [ClothingBackpack, BaseSecurityContraband]
  id: ClothingBackpackSecurity
  name: security backpack
  description: It's a very robust backpack.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/security.rsi

- type: entity
  parent: [ClothingBackpack, BaseSecurityContraband]
  id: ClothingBackpackBrigmedic
  name: brigmedic backpack
  description: It's a very sterile backpack.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/brigmedic.rsi

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackEngineering
  name: engineering backpack
  description: It's a tough backpack for the daily grind of station life.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/engineering.rsi

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackAtmospherics
  name: atmospherics backpack
  description: It's a backpack made of fire resistant fibers. Smells like plasma.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/atmospherics.rsi

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackMedical
  name: medical backpack
  description: It's a backpack especially designed for use in a sterile environment.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/medical.rsi

- type: entity
  parent: [ClothingBackpack, BaseCommandContraband]
  id: ClothingBackpackCaptain
  name: captain's backpack
  description: It's a special backpack made exclusively for Nanotrasen officers.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/captain.rsi

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackMime
  name: mime backpack
  description: A silent backpack made for those silent workers. Silence Co.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/mime.rsi

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackChemistry
  name: chemistry backpack
  description: A backpack specially designed to repel stains and hazardous liquids.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/chemistry.rsi

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackHydroponics
  name: hydroponics backpack
  description: It's a backpack made of all-natural fibers.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/hydroponics.rsi

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackScience
  name: science backpack
  description: A backpack specially designed to repel stains and hazardous liquids.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/science.rsi

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackVirology
  name: virology backpack
  description: A backpack made of hypo-allergenic fibers. It's designed to help prevent the spread of disease. Smells like monkey.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/virology.rsi

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackGenetics
  name: genetics backpack
  description: A backpack designed to be super tough, just in case someone hulks out on you.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/genetics.rsi

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackCargo
  name: cargo backpack
  description: A robust backpack for stealing cargo's loot.
  components:
    - type: Sprite
      sprite: Clothing/Back/Backpacks/cargo.rsi

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackSalvage
  name: salvage bag
  description: A robust backpack for stashing your loot.
  components:
    - type: Sprite
      sprite: Clothing/Back/Backpacks/salvage.rsi

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackMerc
  name: mercenary bag
  description: A backpack that has been in many dangerous places, a reliable combat backpack.
  components:
    - type: Sprite
      sprite: Clothing/Back/Backpacks/merc.rsi

#ERT
- type: entity
  parent: [ ClothingBackpack, ContentsExplosionResistanceBase, BaseCentcommContraband ] # Goobstation
  id: ClothingBackpackERTLeader
  name: ERT leader backpack
  description: A spacious backpack with lots of pockets, worn by the Commander of an Emergency Response Team.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/ertleader.rsi
  - type: Storage
    grid:
    - 0,0,10,3
  - type: ExplosionResistance # Goobstation
    damageCoefficient: 0.1

- type: entity
  parent: ClothingBackpackERTLeader
  id: ClothingBackpackERTSecurity
  name: ERT security backpack
  description: A spacious backpack with lots of pockets, worn by Security Officers of an Emergency Response Team.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/ertsec.rsi

- type: entity
  parent: ClothingBackpackERTLeader
  id: ClothingBackpackERTMedical
  name: ERT medical backpack
  description: A spacious backpack with lots of pockets, worn by Medical Officers of an Emergency Response Team.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/ertmed.rsi

- type: entity
  parent: ClothingBackpackERTLeader
  id: ClothingBackpackERTEngineer
  name: ERT engineer backpack
  description: A spacious backpack with lots of pockets, worn by Engineers of an Emergency Response Team.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/erteng.rsi

- type: entity
  parent: ClothingBackpackERTLeader
  id: ClothingBackpackERTJanitor
  name: ERT janitor backpack
  description: A spacious backpack with lots of pockets, worn by Janitors of an Emergency Response Team.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/ertjanitor.rsi

- type: entity
  parent: ClothingBackpackERTLeader
  id: ClothingBackpackERTClown
  name: ERT clown backpack
  description: A spacious backpack with lots of pockets, worn by Clowns of an Emergency Response Team.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/ertclown.rsi

- type: entity
  parent: ClothingBackpackERTLeader
  id: ClothingBackpackERTChaplain
  name: ERT chaplain backpack
  description: A spacious backpack with lots of pockets, worn by Chaplains of an Emergency Response Team.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/ertchaplain.rsi

- type: entity
  parent: ClothingBackpackERTSecurity
  id: ClothingBackpackDeathSquad
  name: death squad backpack
  description: Holds the kit of CentComm's most feared agents.
  components:
    - type: Storage
      grid:
      - 0,0,10,7 # Goobstation
    - type: ExplosionResistance # Goobstation
      damageCoefficient: 0.1
    - type: Tag
      tags: [] # ignore "WhitelistChameleon" tag

#Syndicate
- type: entity
  parent: [ClothingBackpack, BaseSyndicateContraband]
  id: ClothingBackpackSyndicate
  name: syndicate backpack
  description:
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/syndicate.rsi
  - type: ExplosionResistance
    damageCoefficient: 0.1
  - type: Storage
    grid:
    - 0,0,7,3
    - 8,1,8,3
  - type: StaticPrice
    price: 1000

#Special
- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackHolding
  name: bag of holding
  description: A backpack that opens into a localized pocket of bluespace.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/holding.rsi
    state: holding
    layers:
    - state: holding
    - state: holding-unlit
      shader: unshaded
  - type: Clothing
    equippedPrefix: holding
  - type: Item
    size: Ginormous
  - type: Storage
    maxItemSize: Huge
    grid:
    - 0,0,19,9
  - type: PhysicalComposition #Goobstation - Recycle update
    materialComposition:
      Steel: 500
      Silver: 187
      Plasma: 375
      Uranium: 37
      BSCrystal: 50
  - type: StaticPrice #Goobstation - Recycle update
    price: 1850
  - type: HideContrabandContent #Goobstation Contraband detector - Tecnicly the content is in another dimention

- type: entity
  parent: ClothingBackpackClown
  id: ClothingBackpackCluwne
  name: jiggles von jonkerton
  suffix: Unremoveable
  description: It's a backpack made by Jonk! Co.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/cluwne.rsi
  - type: Unremoveable
    deleteOnDrop: false

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackElectropack
  name: electropack
  suffix: SelfUnremovable
  description: Shocks on the signal. It is used to keep a particularly dangerous criminal under control.
  components:
  - type: Sprite
    sprite: Clothing/Back/Backpacks/electropack.rsi
    state: icon
  - type: Clothing
    stripDelay: 10
    equipDelay: 5 # to avoid accidentally falling into the trap associated with SelfUnremovableClothing
  - type: SelfUnremovableClothing
  - type: ShockOnTrigger
    damage: 5
    duration: 3
    cooldown: 4
  - type: TriggerOnSignal
  - type: DeviceLinkSink
    ports:
      - Trigger

# Debug
- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackDebug
  name: wackpack
  description: What the fuck is this?
  suffix: Debug
  components:
  - type: Storage
    grid:
    - 0,0,3,3
    - 5,0,7,2
    - 0,5,7,5
    - 6,4,7,5
    - 9,2,10,3
    - 9,5,9,5
  - type: Tag
    tags: [] # ignore "WhitelistChameleon" tag

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackDebug2
  name: big wackpack
  description: What the fuck is this?
  suffix: Debug
  components:
  - type: Storage
    grid:
    - 0,0,39,24
  - type: Tag
    tags: [] # ignore "WhitelistChameleon" tag

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackDebug3
  name: gay wackpack
  description: What the fuck is this?
  suffix: Debug
  components:
  - type: Storage
    grid:
    - 0,0,0,3
    - 0,0,2,0
    - 0,3,2,3
    - 2,1,2,1
    - 4,0,4,2
    - 6,0,6,2
    - 5,1,5,1
    - 5,3,5,3
    - 9,0,9,1
    - 8,2,8,3
    - 10,2,10,3
  - type: Tag
    tags: [] # ignore "WhitelistChameleon" tag

- type: entity
  parent: ClothingBackpack
  id: ClothingBackpackDebug4
  name: offset wackpack
  description: What the fuck is this?
  suffix: Debug
  components:
  - type: Storage
    grid:
    - 5,5,11,8
  - type: Tag
    tags: [] # ignore "WhitelistChameleon" tag
