# -- Ammunition Box Base  --
- type: entity
  abstract: true
  parent: BaseItem
  id: RMCBoxBulletsBase
  name: rifle ammunition box (???)
  description: An unknown ammunition box. It comes with a leather strap allowing someone to wear it on their back.
  components:
  - type: Item
    size: Huge
  - type: Sprite
    sprite: _RMC14/Objects/Weapons/Guns/Ammunition/Boxes/modular_boxes.rsi
    layers:
    - state: rifle_box
      color: "#ff0000"
    - state: rifle_box_marking
      color: "#00ff00"
    - state: rifle_box_generic
      color: "#ffcb26"
    - state: rifle_ammo_full_rounds_base
      map: [ "enum.BulletBoxLayers.Fill" ]
    - state: rifle_ammo_full_rounds_color
      map: [ "enum.BulletBoxLayers2.Fill" ]
      color: "#0000ff"
  - type: GenericVisualizer
    visuals:
      enum.BulletBoxLayers.Fill:
        enum.BulletBoxLayers.Fill:
          Empty: { state: rifle_ammo_full_rounds_base, visible: false }
          Low: { state: rifle_ammo_low_rounds_base, visible: true }
          Medium: { state: rifle_ammo_medium_rounds_base, visible: true }
          High: { state: rifle_ammo_high_rounds_base, visible: true }
          Full: { state: rifle_ammo_full_rounds_base, visible: true }
        enum.BulletBoxLayers2.Fill:
          Empty: { state: rifle_ammo_full_rounds_color, visible: false }
          Low: { state: rifle_ammo_low_rounds_color, visible: true }
          Medium: { state: rifle_ammo_medium_rounds_color, visible: true }
          High: { state: rifle_ammo_high_rounds_color, visible: true }
          Full: { state: rifle_ammo_full_rounds_color, visible: true }
  - type: Appearance
  - type: RMCUnfoldCardboard
    spawns:
    - id: RMCSheetCardboard1
  - type: InteractedBlacklist
    blacklist:
      components:
      - Xeno
  - type: Clothing
    quickEquip: false
    slots:
    - Back
  - type: DropOnUseInHand
  - type: BulletBox
  - type: DeployableItem
    leftClickPickup: true
  - type: Tag
    tags:
    - RMCAmmoBox

# -- REG Rifle Ammunition Box Base --
- type: entity
  parent: RMCBoxBulletsBase
  id: RMCBoxBulletsRifle
  name: rifle ammunition box (10x24mm)
  description: A 10x24mm ammunition box. Used to refill M54C MK1, MK2, M4SPR and M54CE2 HAR magazines. It comes with a leather strap allowing someone to wear it on their back.
  components:
  - type: Sprite
    layers:
    - state: rifle_box
      color: "#7b8246"
    - state: rifle_box_marking
      color: "#7c4c1b"
    - state: rifle_box_generic
      color: "#ffcb26"
    - state: rifle_ammo_full_rounds_base
      map: [ "enum.BulletBoxLayers.Fill" ]
    - state: rifle_ammo_full_rounds_color
      map: [ "enum.BulletBoxLayers2.Fill" ]
      color: "#ffc000"
  - type: BulletBox
    bulletType: RMCBoxBulletsRifle

- type: entity
  parent: RMCBoxBulletsRifle
  id: RMCBoxBulletsRifleEmpty
  suffix: Empty
  components:
  - type: Construction
    graph: RMCBoxMagazine
    node: RMCBoxBulletsRifleEmpty
  - type: BulletBox
    bulletType: RMCBoxBulletsRifle
    amount: 0

# -- AP Rifle Ammunition Box Base --
- type: entity
  parent: RMCBoxBulletsBase
  id: RMCBoxBulletsRifleAP
  name: rifle ammunition box (10x24mm AP)
  description: A 10x24mm armor-piercing ammunition box. Used to refill M54C MK2, and M4SPR AP magazines. It comes with a leather strap allowing someone to wear it on their back.
  components:
  - type: Sprite
    layers:
    - state: rifle_box
      color: "#7b8246"
    - state: rifle_box_marking
      color: "#318b11"
    - state: rifle_box_generic
      color: "#ffcb26"
    - state: rifle_ammo_full_rounds_base
      map: [ "enum.BulletBoxLayers.Fill" ]
    - state: rifle_ammo_full_rounds_color
      map: [ "enum.BulletBoxLayers2.Fill" ]
      color: "#318b11"
  - type: BulletBox
    bulletType: RMCBoxBulletsRifleAP

- type: entity
  parent: RMCBoxBulletsRifleAP
  id: RMCBoxBulletsRifleAPEmpty
  suffix: Empty
  components:
  - type: Construction
    graph: RMCBoxMagazine
    node: RMCBoxBulletsRifleAPEmpty
  - type: BulletBox
    bulletType: RMCBoxBulletsRifleAP
    amount: 0

- type: entity
  parent: RMCBoxBulletsBase
  id: RMCBoxBulletsRifleIncendiary
  name: rifle ammunition box (10x24mm Incendiary)
  description: A 10x24mm incendiary ammunition box. Used to refill M54C MK2, and M4SPR incendiary magazines. It comes with a leather strap allowing someone to wear it on their back.
  components:
  - type: Sprite
    layers:
    - state: rifle_box
      color: "#7b8246"
    - state: rifle_box_marking
      color: "#318b11"
    - state: rifle_box_generic
      color: "#ffcb26"
    - state: rifle_ammo_full_rounds_base
      map: [ "enum.BulletBoxLayers.Fill" ]
    - state: rifle_ammo_full_rounds_color
      map: [ "enum.BulletBoxLayers2.Fill" ]
      color: "#318b11"
  - type: BulletBox
    bulletType: RMCBoxBulletsRifleIncendiary

# -- REG SMG Ammunition Box Base --
- type: entity
  parent: RMCBoxBulletsBase
  id: RMCBoxBulletsSMG
  name: SMG ammunition box (10x20mm)
  description: A 10x20mm ammunition box. Used to refill M63 HV and extended magazines. It comes with a leather strap allowing someone to wear it on their back.
  components:
  - type: Sprite
    layers:
    - state: rifle_box
      color: "#727e90"
    - state: rifle_box_marking
      color: "#7c4c1b"
    - state: rifle_box_generic
      color: "#ffcb26"
    - state: rifle_ammo_full_rounds_base
      map: [ "enum.BulletBoxLayers.Fill" ]
    - state: rifle_ammo_full_rounds_color
      map: [ "enum.BulletBoxLayers2.Fill" ]
      color: "#727e90"
  - type: BulletBox
    bulletType: RMCBoxBulletsSMG

- type: entity
  parent: RMCBoxBulletsSMG
  id: RMCBoxBulletsSMGEmpty
  suffix: Empty
  components:
  - type: Construction
    graph: RMCBoxMagazine
    node: RMCBoxBulletsSMGEmpty
  - type: BulletBox
    bulletType: RMCBoxBulletsSMG
    amount: 0

# -- AP SMG Ammunition Box Base --
- type: entity
  parent: RMCBoxBulletsBase
  id: RMCBoxBulletsSMGAP
  name: SMG ammunition box (10x20mm AP)
  description: A 10x20mm armor-piercing ammunition box. Used to refill M63 AP magazines. It comes with a leather strap allowing someone to wear it on their back.
  components:
  - type: Sprite
    layers:
    - state: rifle_box
      color: "#727e90"
    - state: rifle_box_marking
      color: "#318b11"
    - state: rifle_box_generic
      color: "#ffcb26"
    - state: rifle_ammo_full_rounds_base
      map: [ "enum.BulletBoxLayers.Fill" ]
    - state: rifle_ammo_full_rounds_color
      map: [ "enum.BulletBoxLayers2.Fill" ]
      color: "#318b11"
  - type: BulletBox
    bulletType: RMCBoxBulletsSMGAP

- type: entity
  parent: RMCBoxBulletsSMGAP
  id: RMCBoxBulletsSMGAPEmpty
  suffix: Empty
  components:
  - type: Construction
    graph: RMCBoxMagazine
    node: RMCBoxBulletsSMGAPEmpty
  - type: BulletBox
    bulletType: RMCBoxBulletsSMGAP
    amount: 0

# -- SG Ammunition Box Base --
- type: entity
  parent: RMCBoxBulletsBase
  id: RMCBoxBulletsSmartGun
  name: smart gun ammunition box (10x30mm)
  description: A 10x30mm ammunition box. Used to refill Smart Gun magazines. It comes with a leather strap allowing someone to wear it on their back.
  components:
  - type: Sprite
    layers:
    - state: rifle_box
      color: "#7b8246"
    - state: rifle_box_marking
      color: "#ffcb26"
    - state: rifle_box_generic
      color: "#ffcb26"
    - state: rifle_ammo_full_rounds_base
      map: [ "enum.BulletBoxLayers.Fill" ]
    - state: rifle_ammo_full_rounds_color
      map: [ "enum.BulletBoxLayers2.Fill" ]
      color: "#ffc000"
  - type: BulletBox
    bulletType: RMCBoxBulletsSmartGun

- type: entity
  parent: RMCBoxBulletsSmartGun
  id: RMCBoxBulletsSmartGunEmpty
  suffix: Empty
  components:
  - type: BulletBox
    bulletType: RMCBoxBulletsSmartGun
    amount: 0

# -- REG Pistol Ammunition Box Base --
- type: entity
  parent: RMCBoxBulletsBase
  id: RMCBoxBulletsPistol
  name: pistol ammunition box (10x20mm-APC)
  description: A 10x20mm-APC ammunition box. Used to refill M13 regular, extended and drum magazines. It comes with a leather strap allowing to wear it on the back.
  components:
  - type: Sprite
    layers:
    - state: rifle_box
      color: "#8F7D70"
    - state: rifle_box_marking
      color: "#704506"
    - state: rifle_box_generic
      color: "#ffcb26"
    - state: rifle_ammo_full_rounds_base
      map: [ "enum.BulletBoxLayers.Fill" ]
    - state: rifle_ammo_full_rounds_color
      map: [ "enum.BulletBoxLayers2.Fill" ]
      color: "#704506"
  - type: BulletBox
    bulletType: RMCBoxBulletsPistol
    max: 984
    amount: 984

- type: entity
  parent: RMCBoxBulletsPistol
  id: RMCBoxBulletsPistolEmpty
  suffix: Empty
  components:
  - type: Construction
    graph: RMCBoxMagazine
    node: RMCBoxBulletsPistolEmpty
  - type: BulletBox
    bulletType: RMCBoxBulletsPistol
    amount: 0

# -- AP Pistol Ammunition Box Base --
- type: entity
  parent: RMCBoxBulletsBase
  id: RMCBoxBulletsPistolAP
  name: pistol ammunition box (10x20mm-APC (AP))
  description: A 10x20mm-APC armor-piercing ammunition box. Used to refill M13 regular, extended and drum AP magazines. It comes with a leather strap allowing to wear it on the back.
  components:
  - type: Sprite
    layers:
    - state: rifle_box
      color: "#8F7D70"
    - state: rifle_box_marking
      color: "#0A4306"
    - state: rifle_box_generic
      color: "#ffcb26"
    - state: rifle_ammo_full_rounds_base
      map: [ "enum.BulletBoxLayers.Fill" ]
    - state: rifle_ammo_full_rounds_color
      map: [ "enum.BulletBoxLayers2.Fill" ]
      color: "#0A4306"
  - type: BulletBox
    bulletType: RMCBoxBulletsPistolAP
    max: 984
    amount: 984

- type: entity
  parent: RMCBoxBulletsPistolAP
  id: RMCBoxBulletsPistolAPEmpty
  suffix: Empty
  components:
  - type: Construction
    graph: RMCBoxMagazine
    node: RMCBoxBulletsPistolAPEmpty
  - type: BulletBox
    bulletType: RMCBoxBulletsPistolAP
    amount: 0


# TWE Ammunition Boxes
# -- REG 7x43mm Rifle Ammunition Box --
- type: entity
  parent: RMCBoxBulletsBase
  id: RMCBoxBulletsRifleL90
  name: rifle ammunition box (7x43mm)
  description: A 7x43mm ammunition box. Used to refill L90/91 magazines. It comes with a leather strap allowing someone to wear it on their back.
  components:
  - type: Sprite
    layers:
    - state: rifle_box
      color: "#3a3a4b"
    - state: rifle_box_marking
      color: "#7c4c1b"
    - state: rifle_box_generic
      color: "#7c4c1b"
    - state: rifle_ammo_full_rounds_base
      map: [ "enum.BulletBoxLayers.Fill" ]
    - state: rifle_ammo_full_rounds_color
      map: [ "enum.BulletBoxLayers2.Fill" ]
      color: "#ffc000"
  - type: BulletBox
    bulletType: RMCBoxBulletsRifleL90

- type: entity
  parent: RMCBoxBulletsRifleL90
  id: RMCBoxBulletsRifleL90Empty
  suffix: Empty
  components:
  - type: BulletBox
    bulletType: RMCBoxBulletsRifleL90
    amount: 0

# -- AP 7x43mm Rifle Ammunition Box --
- type: entity
  parent: RMCBoxBulletsBase
  id: RMCBoxBulletsRifleL90AP
  name: rifle ammunition box (7x43mm AP)
  description: A 7x43mm armor-piercing ammunition box. Used to refill L90/91 AP magazines. It comes with a leather strap allowing someone to wear it on their back.
  components:
  - type: Sprite
    layers:
    - state: rifle_box
      color: "#3a3a4b"
    - state: rifle_box_marking
      color: "#318b11"
    - state: rifle_box_generic
      color: "#7c4c1b"
    - state: rifle_ammo_full_rounds_base
      map: [ "enum.BulletBoxLayers.Fill" ]
    - state: rifle_ammo_full_rounds_color
      map: [ "enum.BulletBoxLayers2.Fill" ]
      color: "#318b11"
  - type: BulletBox
    bulletType: RMCBoxBulletsRifleL90AP

- type: entity
  parent: RMCBoxBulletsRifleL90AP
  id: RMCBoxBulletsRifleL90APEmpty
  suffix: Empty
  components:
  - type: BulletBox
    bulletType: RMCBoxBulletsRifleL90AP
    amount: 0

# -- REG 8.88x51mm Rifle Ammunition Box --
- type: entity
  parent: RMCBoxBulletsBase
  id: RMCBoxBulletsRifleL24
  name: rifle ammunition box (8.88x51mm)
  description: An 8.88x51mm ammunition box. Used to refill L24 and L64A3 magazines. It comes with a leather strap allowing someone to wear it on their back. # TODO RMC14 rename and implement L64A3
  components:
  - type: Sprite
    layers:
    - state: rifle_box
      color: "#323b3e"
    - state: rifle_box_marking
      color: "#7c4c1b"
    - state: rifle_box_generic
      color: "#ffcb26"
    - state: rifle_ammo_full_rounds_base
      map: [ "enum.BulletBoxLayers.Fill" ]
    - state: rifle_ammo_full_rounds_color
      map: [ "enum.BulletBoxLayers2.Fill" ]
      color: "#ffc000"
  - type: BulletBox
    bulletType: RMCBoxBulletsRifleL24

- type: entity
  parent: RMCBoxBulletsRifleL24
  id: RMCBoxBulletsRifleTSEEmpty
  suffix: Empty
  components:
  - type: BulletBox
    bulletType: RMCBoxBulletsRifleL24
    amount: 0

# -- AP 8.88x51mm Rifle Ammunition Box --
- type: entity
  parent: RMCBoxBulletsBase
  id: RMCBoxBulletsRifleL24AP
  name: rifle ammunition box (8.88x51mm AP)
  description: An 8.88x51mm ammunition box. Used to refill L24 and L64A3 AP magazines. It comes with a leather strap allowing someone to wear it on their back.
  components:
  - type: Sprite
    layers:
    - state: rifle_box
      color: "#323b3e"
    - state: rifle_box_marking
      color: "#318b11"
    - state: rifle_box_generic
      color: "#ffcb26"
    - state: rifle_ammo_full_rounds_base
      map: [ "enum.BulletBoxLayers.Fill" ]
    - state: rifle_ammo_full_rounds_color
      map: [ "enum.BulletBoxLayers2.Fill" ]
      color: "#318b11"
  - type: BulletBox
    bulletType: RMCBoxBulletsRifleL24AP

- type: entity
  parent: RMCBoxBulletsRifleL24AP
  id: RMCBoxBulletsRifleTSEAPEmpty
  suffix: Empty
  components:
  - type: BulletBox
    bulletType: RMCBoxBulletsRifleL24AP
