- type: entity
  id: MagazineBR64
  name: BR64 magazine
  description: Standart EarthGov type of heavy magazines.
  parent: BaseItem
  components:
  - type: Tag
    tags:
      - MagazineBR64
  - type: BallisticAmmoProvider
    mayTransfer: true
    capacity: 20
    proto: CartridgeRifleHeavySP
    whitelist:
      tags:
        - CartridgeHeavyRifle
  - type: ContainerContainer
    containers:
      ballistic-ammo: !type:Container
  - type: Item
    size: Small
    sprite: _Sunrise/Objects/Weapons/Guns/Ammunition/Magazines/Rifle/br64_mag.rsi
  - type: Sprite
    netsync: false
    sprite: _Sunrise/Objects/Weapons/Guns/Ammunition/Magazines/Rifle/br64_mag.rsi
    layers:
    - state: base
      map: ["enum.GunVisualLayers.Base"]
    - state: mag-1
      map: ["enum.GunVisualLayers.Mag"]
  - type: MagazineVisuals
    magState: mag
    steps: 2
    zeroVisible: false
  - type: Appearance

# region Bauer127 Mag
- type: entity
  id: BaseMagazineBauer127
  name: magazine (15mm anti-materiel)
  description: A large magazine for a heavy weapon, holds 15x115mm anti-materiel rounds.
  parent: [ BaseItem, BaseMajorContraband ]
  abstract: true
  components:
  - type: Sprite
    netsync: false
    sprite: _Sunrise/Objects/Weapons/Guns/Ammunition/Magazines/Rifle/sr127_mag.rsi
    layers:
    - state: base
      map: ["enum.GunVisualLayers.Base"]
    - state: mag-6
  - type: Tag
    tags:
      - MagazineBauer127
  - type: Item
    size: Small
  - type: BallisticAmmoProvider
    mayTransfer: true
    whitelist:
      tags:
        - CartridgeAntiMateriel
    capacity: 7
  - type: ContainerContainer
    containers:
      ballistic-ammo: !type:Container
  - type: MagazineVisuals
    magState: mag
    steps: 7
    zeroVisible: false
  - type: Appearance

- type: entity
  id: MagazineBauer127
  name: magazine (15mm anti-materiel)
  description: A large magazine for a heavy weapon, holds 15x115mm anti-materiel rounds.
  parent: BaseMagazineBauer127
  components:
  - type: BallisticAmmoProvider
    proto: CartridgeAntiMateriel
  - type: Sprite
    layers:
    - state: base
      map: ["enum.GunVisualLayers.Base"]
    - state: mag-6
      map: ["enum.GunVisualLayers.Mag"]
  - type: Item
    inhandVisuals:
      left:
      - state: inhand-left-mag
      right:
      - state: inhand-right-mag

- type: entity
  id: MagazineBauer127Large
  name: large magazine (15mm space anti-materiel)
  parent: MagazineBauer127
  components:
  - type: Sprite
    scale: 1,1.5
    sprite: _Sunrise/Objects/Weapons/Guns/Ammunition/Magazines/Rifle/sr127_mag.rsi
  - type: BallisticAmmoProvider
    proto: CartridgeAntiMateriel
    capacity: 21

- type: entity
  id: MagazineBauer127Penetrator
  name: magazine (15mm penetrator)
  parent: BaseMagazineBauer127
  components:
  - type: BallisticAmmoProvider
    proto: CartridgeAntiMaterielPenetrator
  - type: Sprite
    layers:
    - state: base
      map: ["enum.GunVisualLayers.Base"]
    - state: mag-6
      map: ["enum.GunVisualLayers.Mag"]
    - state: stripe
      color: "#9b0000"
  - type: Item
    inhandVisuals:
      left:
      - state: inhand-left-mag
      - state: inhand-left-stripe
        color: "#9b0000"
      right:
      - state: inhand-right-mag
      - state: inhand-right-stripe
        color: "#9b0000"

- type: entity
  id: MagazineBauer127Frag
  name: magazine (15mm frag)
  parent: BaseMagazineBauer127
  components:
  - type: BallisticAmmoProvider
    proto: CartridgeAntiMaterielFrag
  - type: Sprite
    layers:
    - state: base
      map: ["enum.GunVisualLayers.Base"]
    - state: mag-6
      map: ["enum.GunVisualLayers.Mag"]
    - state: stripe
      color: "#7ea53b"
  - type: Item
    inhandVisuals:
      left:
      - state: inhand-left-mag
      - state: inhand-left-stripe
        color: "#7ea53b"
      right:
      - state: inhand-right-mag
      - state: inhand-right-stripe
        color: "#7ea53b"

- type: entity
  id: MagazineBauer127Blast
  name: magazine (15mm blast)
  parent: BaseMagazineBauer127
  components:
  - type: BallisticAmmoProvider
    proto: CartridgeAntiMaterielBlast
  - type: Sprite
    layers:
    - state: base
      map: ["enum.GunVisualLayers.Base"]
    - state: mag-6
      map: ["enum.GunVisualLayers.Mag"]
    - state: stripe
      color: "#8d6425"
  - type: Item
    inhandVisuals:
      left:
      - state: inhand-left-mag
      - state: inhand-left-stripe
        color: "#8d6425"
      right:
      - state: inhand-right-mag
      - state: inhand-right-stripe
        color: "#8d6425"

- type: entity
  id: MagazineBauer127Emp
  name: magazine (15mm emp)
  parent: BaseMagazineBauer127
  components:
  - type: BallisticAmmoProvider
    proto: CartridgeAntiMaterielEmp
  - type: Sprite
    layers:
    - state: base
      map: ["enum.GunVisualLayers.Base"]
    - state: mag-6
      map: ["enum.GunVisualLayers.Mag"]
    - state: stripe
      color: "#005396"
  - type: Item
    inhandVisuals:
      left:
      - state: inhand-left-mag
      - state: inhand-left-stripe
        color: "#005396"
      right:
      - state: inhand-right-mag
      - state: inhand-right-stripe
        color: "#005396"

# region other Magazine
- type: entity
  id: BaseMagazineDragunov
  name: "magazine Dragunov (7,62mmR)"
  parent: [ BaseItem, BaseSecurityContraband ]
  abstract: true
  components:
  - type: Tag
    tags:
    - MagazineDragunov
  - type: Item
    size: Small
  - type: BallisticAmmoProvider
    mayTransfer: true
    whitelist:
      tags:
      - CartridgeHeavyRifleR
    capacity: 10
  - type: ContainerContainer
    containers:
      ballistic-ammo: !type:Container
  - type: Sprite
    sprite: _Sunrise/Objects/Weapons/Guns/Ammunition/Magazines/Rifle/dragunov_mag.rsi
    layers:
    - state: base
      map: ["enum.GunVisualLayers.Base"]
    - state: mag-1
      map: ["enum.GunVisualLayers.Mag"]
  - type: MagazineVisuals
    magState: mag
    steps: 2
    zeroVisible: false
  - type: Appearance

- type: entity
  id: MagazineDragunovExtended
  name: "magazine Dragunov (7,62mmR)"
  suffix: Sunrise
  parent: BaseMagazineDragunov
  components:
  - type: BallisticAmmoProvider
    proto: CartridgeHeavyRifleRSP
    capacity: 20
  - type: Sprite
    sprite: _Sunrise/Objects/Weapons/Guns/Ammunition/Magazines/Rifle/dragunov_mag.rsi
    layers:
    - state: base-1
      map: ["enum.GunVisualLayers.Base"]
    - state: mag-1
      map: ["enum.GunVisualLayers.Mag"]
  - type: Item
    inhandVisuals:
      left:
      - state: inhand-left-mag
      right:
      - state: inhand-right-mag

- type: entity
  id: MagazineDragunov
  name: "magazine Dragunov (7,62mmR)"
  suffix: Sunrise
  parent: BaseMagazineDragunov
  components:
  - type: BallisticAmmoProvider
    proto: CartridgeHeavyRifleRSP
  - type: Sprite
    layers:
    - state: base
      map: ["enum.GunVisualLayers.Base"]
    - state: mag-1
      map: ["enum.GunVisualLayers.Mag"]
  - type: Item
    inhandVisuals:
      left:
      - state: inhand-left-mag
      right:
      - state: inhand-right-mag

- type: entity
  id: MagazineDragunovEmpty
  name: "magazine (7,62mmR any)"
  suffix: Sunrise, empty
  parent: MagazineDragunov
  components:
  - type: BallisticAmmoProvider
    proto: null
  - type: Sprite
    layers:
    - state: base
      map: ["enum.GunVisualLayers.Base"]
    - state: mag-1
      map: ["enum.GunVisualLayers.Mag"]
  - type: Item
    inhandVisuals:
      left:
      - state: inhand-left-mag
      right:
      - state: inhand-right-mag

- type: entity
  id: MagazineDragunovIncendiary
  name: "magazine (7,62mmR incendiary)"
  suffix: Sunrise
  parent: MagazineDragunov
  components:
  - type: BallisticAmmoProvider
    proto: CartridgeHeavyRifleRIncendiary
  - type: Sprite
    layers:
    - state: base
      map: ["enum.GunVisualLayers.Base"]
    - state: mag-1
      map: ["enum.GunVisualLayers.Mag"]
    - state: stripe
      color: "#ff6e52"
  - type: Item
    inhandVisuals:
      left:
      - state: inhand-left-mag
      - state: inhand-left-stripe
        color: "#ff6e52"
      right:
      - state: inhand-right-mag
      - state: inhand-right-stripe
        color: "#ff6e52"

- type: entity
  id: MagazineDragunovPractice
  name: "magazine (7,62mmR practice)"
  suffix: Sunrise
  parent: BaseMagazineDragunov
  components:
  - type: BallisticAmmoProvider
    proto: CartridgeHeavyRifleRPractice
  - type: Sprite
    layers:
    - state: base
      map: ["enum.GunVisualLayers.Base"]
    - state: mag-1
      map: ["enum.GunVisualLayers.Mag"]
    - state: stripe
      color: "#dbdbdb"
  - type: Item
    inhandVisuals:
      left:
      - state: inhand-left-mag
      - state: inhand-left-stripe
        color: "#dbdbdb"
      right:
      - state: inhand-right-mag
      - state: inhand-right-stripe
        color: "#dbdbdb"

- type: entity
  id: MagazineDragunovUranium
  name: "magazine (7,62mmR uranium)"
  suffix: Sunrise
  parent: BaseMagazineDragunov
  components:
  - type: BallisticAmmoProvider
    proto: CartridgeHeavyRifleRUranium
  - type: Sprite
    layers:
    - state: base
      map: ["enum.GunVisualLayers.Base"]
    - state: mag-1
      map: ["enum.GunVisualLayers.Mag"]
    - state: stripe
      color: "#00cd42"
  - type: Item
    inhandVisuals:
      left:
      - state: inhand-left-mag
      - state: inhand-left-stripe
        color: "#00cd42"
      right:
      - state: inhand-right-mag
      - state: inhand-right-stripe
        color: "#00cd42"
