- type: entity
  name: BaseSMG
  parent: BaseItem
  id: BaseWeaponSubMachineGun
  description: A rooty tooty point and shooty.
  abstract: true
  components:
  - type: Sprite
  - type: Item
    size: Large
  - type: Clothing
    sprite: Objects/Weapons/Guns/SMGs/atreides.rsi
    quickEquip: false
    slots:
    - Back
    - suitStorage
  - type: AmmoCounter
  - type: Gun
    minAngle: 2
    maxAngle: 16
    fireRate: 8
    burstFireRate: 8
    angleIncrease: 3
    angleDecay: 16
    selectedMode: FullAuto
    projectileSpeed: 50 # Mono
    availableModes:
    - SemiAuto
    - FullAuto
    soundGunshot:
      path: /Audio/Weapons/Guns/Gunshots/smg.ogg
    defaultDirection: 1, 0
  - type: ChamberMagazineAmmoProvider
    soundRack:
      path: /Audio/Weapons/Guns/Cock/smg_cock.ogg
  - type: ItemSlots
    slots:
      gun_magazine:
        name: Magazine
        startingItem: Magazine9x19mmSubMachineGunFMJ
        insertSound: /Audio/Weapons/Guns/MagIn/smg_magin.ogg
        ejectSound: /Audio/Weapons/Guns/MagOut/smg_magout.ogg
        priority: 2
        whitelist:
          tags:
            - Magazine9x19mmSubMachineGunFMJ
        whitelistFailPopup: gun-magazine-whitelist-fail
      gun_chamber:
        name: Chamber
        startingItem: Cartridge9x19mmFMJ
        priority: 1
        whitelist:
          tags:
            - Cartridge9x19mmFMJ
  - type: ContainerContainer
    containers:
      gun_magazine: !type:ContainerSlot
      gun_chamber: !type:ContainerSlot
  - type: StaticPrice
    price: 500
  - type: ItemTax # Mono
    taxAccounts:
      nfsd: 0.2
  - type: WieldedCrosshair
    rsi:
      sprite: _RMC14/Interface/MousePointer/pistol_mouse.rsi
      state: all
  # Goobstation edit start
  - type: EmitSoundOnPickup
    sound:
      collection: SMGPickUp
  - type: EmitSoundOnDrop
    sound:
      collection: SMGDrop
  - type: EmitSoundOnLand
    sound:
      collection: SMGDrop
  # Goobstation edit end

- type: entity
  name: MA PDW-58 Atreides (5.7x28mm)
  parent: BaseWeaponSubMachineGun
  id: WeaponSubMachineGunAtreides
  description: Midnight Arms Co. Streamlined SMG that's commonly found use among uprisings and criminals. Uses 5.7x28mm ammo.
  components:
  - type: Sprite
    sprite: Objects/Weapons/Guns/SMGs/atreides.rsi
    layers:
    - state: base
      map: ["enum.GunVisualLayers.Base"]
    - state: mag-0
      map: ["enum.GunVisualLayers.Mag"]
  - type: Gun
    fireRate: 8.5
    soundGunshot:
      path: /Audio/_Mono/Weapons/Guns/SmallArms/Gunshots/atreides_fire.ogg
  - type: MagazineVisuals
    magState: mag
    steps: 1
    zeroVisible: true
  - type: Appearance
  - type: StaticPrice # Mono
    price: 2000
  - type: ItemSlots
    slots:
       gun_magazine:
          name: Magazine
          startingItem: Magazine57x28mmSubMachineGunFMJ
          insertSound: /Audio/Weapons/Guns/MagIn/smg_magin.ogg
          ejectSound: /Audio/Weapons/Guns/MagOut/smg_magout.ogg
          priority: 2
          whitelist:
            tags:
              - Magazine57x28mmSubMachineGunFMJ
          whitelistFailPopup: gun-magazine-whitelist-fail
       gun_chamber:
          name: Chamber
          startingItem: Cartridge57x28mmFMJ
          priority: 1
          whitelist:
            tags:
              - Cartridge57x28mmFMJ

- type: entity
  name: CS C-20r submachine gun (9x19mm)
  parent: BaseWeaponSubMachineGun
  id: WeaponSubMachineGunC20r
  description: A Corporate-Era SMG, once used by Nuclear Operatives, it now finds purchase among the Phaethon Dynasty. Uses 9x19mm ammo.
  components:
  - type: Sprite
    sprite: Objects/Weapons/Guns/SMGs/c20r.rsi
    layers:
    - state: base
      map: ["enum.GunVisualLayers.Base"]
    - state: mag-0
      map: ["enum.GunVisualLayers.Mag"]
  - type: Clothing
    sprite: Objects/Weapons/Guns/SMGs/c20r.rsi
  - type: Wieldable
    unwieldOnUse: false
  - type: GunWieldBonus
    minAngle: -19
    maxAngle: -16
  - type: Gun
    minAngle: 21
    maxAngle: 32
    shotsPerBurst: 5
    availableModes:
    - Burst
    - FullAuto
    - SemiAuto
    soundGunshot:
      path: /Audio/Weapons/Guns/Gunshots/c-20r.ogg
  - type: ChamberMagazineAmmoProvider
    autoEject: true
  - type: MagazineVisuals
    magState: mag
    steps: 6
    zeroVisible: true
  - type: Appearance
  - type: StaticPrice # Mono
    price: 625

- type: entity
  name: TCA M-5 Drozd (.45 ACP)
  parent: BaseWeaponSubMachineGun
  id: WeaponSubMachineGunDrozd
  description: An SMG that once found use among NT security forces, now has found itself as one of the most reliable boarding and anti-boarding weapons on the market. Uses .45 ACP ammo.
  components:
    - type: Item # Mono
      size: Large
      sprite: _Mono/Objects/Weapons/Guns/SMGs/drozd_inhands_32x.rsi
    - type: Sprite
      sprite: _Mono/Objects/Weapons/Guns/SMGs/drozd.rsi # Mono
      layers:
        - state: base
          map: ["enum.GunVisualLayers.Base"]
        - state: mag-0
          map: ["enum.GunVisualLayers.Mag"]
    - type: Clothing
      sprite: _Mono/Objects/Weapons/Guns/SMGs/drozd_inhands_32x.rsi # Mono
    - type: Wieldable
      unwieldOnUse: false
    - type: GunWieldBonus
      minAngle: -19
      maxAngle: -20 # -16 -> -20 - Mono
    - type: ChamberMagazineAmmoProvider # Mono
      soundRack:
        path: /Audio/Weapons/Guns/Cock/ltrifle_cock.ogg
    - type: Gun
      minAngle: 21
      maxAngle: 32
      fireRate: 6
      burstFireRate: 12
      soundGunshot:
        path: /Audio/_Mono/Weapons/Guns/SmallArms/Gunshots/smg.ogg # Mono
      availableModes:
      - Burst
      - FullAuto
      - SemiAuto
      shotsPerBurst: 3
      burstCooldown: 0.25
    - type: ItemSlots
      slots:
        gun_magazine:
          name: Magazine
          startingItem: Magazine45_ACPSubMachineGunFMJ
          insertSound: /Audio/_Mono/Weapons/Guns/SmallArms/MagIn/skm_magin.ogg # Mono
          ejectSound: /Audio/_Mono/Weapons/Guns/SmallArms/MagOut/m16_magout.ogg # Mono
          priority: 2
          whitelist:
            tags:
              - Magazine45_ACPSubMachineGunFMJ
          whitelistFailPopup: gun-magazine-whitelist-fail
        gun_chamber:
          name: Chamber
          startingItem: Cartridge45_ACPFMJ
          priority: 1
          whitelist:
            tags:
              - Cartridge45_ACPFMJ
    - type: MagazineVisuals
      magState: mag
      steps: 6
      zeroVisible: true
    - type: Appearance
    - type: StaticPrice # Mono
      price: 525
    - type: PirateBountyItem # Mono
      id: StandardFactionLongarm


- type: entity
  name: UI WT550 (4.6x30mm)
  parent: BaseWeaponSubMachineGun
  id: WeaponSubMachineGunWt550
  description: An excellent SMG, produced by a Black Market Arms Company known as Ullman Industries. Uses 4.6x30mm ammo. On the receiver is a label that says 'for authorized use only.'
  components:
  - type: Sprite
    sprite: Objects/Weapons/Guns/SMGs/wt550.rsi
    layers:
      - state: base
        map: ["enum.GunVisualLayers.Base"]
      - state: base-unshaded
        map: ["enum.GunVisualLayers.BaseUnshaded"]
        shader: unshaded
      - state: mag-0
        map: ["enum.GunVisualLayers.Mag"]
      - state: mag-unshaded-0
        map: ["enum.GunVisualLayers.MagUnshaded"]
        shader: unshaded
  - type: Clothing
    sprite: Objects/Weapons/Guns/SMGs/wt550.rsi
  - type: ChamberMagazineAmmoProvider
    boltClosed: null
  - type: Gun
    fireRate: 5.5
    minAngle: 1
    maxAngle: 6
    angleIncrease: 1.5
    angleDecay: 6
    selectedMode: FullAuto
    shotsPerBurst: 5
    burstCooldown: 0.2
    burstFireRate: 7
    availableModes:
    - Burst
    - FullAuto
    - SemiAuto
    soundGunshot: # Mono change - Sound for WT
      path: /Audio/_Mono/Weapons/Guns/SmallArms/Gunshots/wt_fire.ogg
  - type: ItemSlots
    slots:
      gun_magazine:
        name: Magazine
        startingItem: Magazine46x30mmSubMachineGunTopMountedFMJ
        insertSound: /Audio/Weapons/Guns/MagIn/smg_magin.ogg
        ejectSound: /Audio/Weapons/Guns/MagOut/smg_magout.ogg
        priority: 2
        whitelist:
          tags:
            - Magazine46x30mmSubMachineGunTopMountedFMJ
        whitelistFailPopup: gun-magazine-whitelist-fail
      gun_chamber:
        name: Chamber
        startingItem: Cartridge46x30mmFMJ
        priority: 1
        whitelist:
          tags:
            - Cartridge46x30mmFMJ
  - type: MagazineVisuals
    magState: mag
    steps: 6
    zeroVisible: true
  - type: Appearance
  - type: StaticPrice # Mono
    price: 1000
  - type: PirateBountyItem # Mono
    id: StandardFactionLongarm
