- type: entity
  parent: CMBarricadeBase
  id: CMBarricadeSandbag
  name: sandbag barricade
  description: A makeshift barricade made out of the sand from the ground. Tough to beat but easy to pierce.
  components:
  - type: BarricadeSandbag
  - type: Climbable
  - type: MeleeSound
    soundGroups:
      Brute:
        path:
          "/Audio/Effects/Footsteps/snowstep1.ogg"
  - type: Sprite
    sprite: _RMC14/Structures/Walls/Barricades/barricade.rsi
    layers:
    - state: sandbag
    - map: [ "acided" ]
    drawdepth: WallTops
  - type: GenericVisualizer
    visuals:
      enum.BarbedWireVisualLayers.Wire:
        barbWired:
          UnWired: { state: sandbag_wire, visible: false }
          WiredClosed: { state: sandbag_wire, visible: true }
      enum.SprayAcidedVisuals.Acided:
        acided:
          True:
            sprite: _RMC14/Effects/xeno_spray_acid.rsi
            state: acid
            visible: true
          False:
            visible: false
  - type: Damageable
    damageContainer: Inorganic
    damageModifierSet: CMSandbag
  - type: Destructible
    thresholds:
    - trigger:
        !type:DamageTrigger
        damage: 1300
      behaviors:
      - !type:PlaySoundBehavior
        sound:
          collection: MetalBreak
      - !type:DoActsBehavior
        acts: [ "Destruction" ]
  - type: DamageVisuals
    thresholds: [4, 8, 12]
    damageDivisor: 25
    trackAllDamage: true
    damageOverlay:
      sprite: _RMC14/Structures/Walls/Barricades/sandbag_cracks.rsi
  - type: Barbed
    thornsDamage:
      types:
        Slash: 10
  - type: Physics
  - type: Fixtures
    fixtures:
      fix1:
        shape: !type:PhysShapeAabb
          bounds: "-0.49,-0.45,0.49,-0.55"
        mask:
        - FullTileMask
        layer:
        - WallLayer
        - BulletImpassable
  - type: BarricadeBlock
    bidirectional: true
    blocking: 75


- type: entity
  parent: BaseItem
  id: CMSandbagEmpty
  name: empty sandbags
  description: Some empty sandbags, best to fill them up if you want to use them.
  components:
  - type: Item
    sprite: _RMC14/Objects/Misc/sandbags.rsi
    inhandVisuals:
      left:
      - state: stack-inhand-left
      right:
      - state: stack-inhand-right
    size: Small
  - type: Sprite
    sprite: _RMC14/Objects/Misc/sandbags.rsi
    layers:
    - state: sandbag_stack
    - map: [ "acided" ]
  - type: EmptySandbag
  - type: Stack
    stackType: CMSandbagEmpty
    count: 1

- type: entity
  parent: CMSandbagEmpty
  id: CMSandbagEmpty50
  suffix: "50"
  components:
  - type: Stack
    stackType: CMSandbagEmpty
    count: 50

- type: entity
  parent: CMSandbagEmpty
  id: CMSandbagEmpty25
  suffix: "25"
  components:
  - type: Stack
    stackType: CMSandbagEmpty
    count: 25

- type: entity
  parent: CMSandbagEmpty
  id: CMSandbagEmpty10
  suffix: "10"
  components:
  - type: Stack
    stackType: CMSandbagEmpty
    count: 10

- type: entity
  parent: BaseItem
  id: CMSandbagFull
  name: sandbags
  description: Some bags filled with sand. For now, just cumbersome, but soon to be used for fortifications.
  components:
  - type: Item
    sprite: _RMC14/Objects/Misc/sandbags.rsi
    inhandVisuals:
      left:
      - state: pile-inhand-left
      right:
      - state: pile-inhand-right
    size: Huge
  - type: Sprite
    sprite: _RMC14/Objects/Misc/sandbags.rsi
    layers:
    - state: sandbag_pile
    - map: [ "acided" ]
  - type: FullSandbag
  - type: Stack
    stackType: CMSandbagFull
    count: 1
  - type: InteractedBlacklist
    blacklist:
      components:
      - Xeno

- type: entity
  parent: CMSandbagFull
  id: CMSandbagFull50
  suffix: "50"
  components:
  - type: Stack
    stackType: CMSandbagFull
    count: 50

- type: entity
  parent: CMSandbagFull
  id: CMSandbagFull25
  suffix: "25"
  components:
  - type: Stack
    stackType: CMSandbagFull
    count: 25

- type: entity
  parent: CMSandbagFull
  id: CMSandbagFull5
  suffix: "5"
  components:
  - type: Stack
    stackType: CMSandbagFull
    count: 5

- type: stack
  id: CMSandbagEmpty
  name: empty sandbags
  spawn: CMSandbagEmpty
  maxCount: 50

- type: stack
  id: CMSandbagFull
  name: empty sandbags
  spawn: CMSandbagFull
  maxCount: 50

- type: entity
  parent: CMBarricadeSandbag
  id: RMCBarricadeSandbagSoro
  suffix: Brown
  components:
  - type: Sprite
    color: "#a98c7c"
