# SPDX-FileCopyrightText: 2024 Firewatch <54725557+musicmanvr@users.noreply.github.com>
# SPDX-FileCopyrightText: 2024 metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Aiden <28298836+Aidenkrz@users.noreply.github.com>
# SPDX-FileCopyrightText: 2025 Ilya246 <57039557+Ilya246@users.noreply.github.com>
#
# SPDX-License-Identifier: AGPL-3.0-or-later

- type: entity
  parent: BaseItem
  id: SnapPop
  name: snap pop
  description: Throw it at the floor and listen to it POP!
  components:
  - type: Sprite
    sprite: Objects/Fun/snap_pops.rsi
    state: icon
  - type: Item
    size: Tiny
  - type: Damageable
    damageContainer: Inorganic
  - type: Destructible
    thresholds:
    - trigger:
        !type:DamageTrigger
        damage: 1
      behaviors:
      - !type:DoActsBehavior
        acts: ["Destruction"]
      - !type:PlaySoundBehavior
        sound:
          path: /Audio/Effects/snap.ogg
      - !type:ExplodeBehavior
  - type: DamageOnLand
    damage:
      types:
        Blunt: 3
  - type: Explosive
    explosionType: Default
    # Cosmetic explosion :tf:
    maxIntensity: 0.01
    intensitySlope: 1
    totalIntensity: 0.01
  # Goobstation
  - type: Tag
    tags:
    - SnapPop

- type: entity
  parent: BaseStorageItem
  id: SnapPopBox
  name: snap pop box
  description: Contains snap pops for a few minutes of popping fun!
  components:
  - type: Item
    size: Normal
  - type: Sprite
    sprite: Objects/Fun/snap_pops.rsi
    state: box
  - type: Storage
    grid:
    - 0,0,4,3
    areaInsert: true
    maxItemSize: Tiny
  - type: StorageFill
    contents:
      - id: SnapPop
        amount: 5
  - type: Dumpable
