Skip to content

Commit

Permalink
EMP
Browse files Browse the repository at this point in the history
  • Loading branch information
dvir001 committed Jul 28, 2023
1 parent 84002c3 commit ce54ec6
Show file tree
Hide file tree
Showing 20 changed files with 170 additions and 79 deletions.
2 changes: 1 addition & 1 deletion Content.Server/_NF/M_Emp/M_EmpSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
using Content.Server.DeviceLinking.Systems;

// TO ANYONE LOOKING AT THIS CODE, IM SORRY
// This code was reused for the salvage magnet and is a mess right now as it is, it has no known issues with it as for now but its not cleaned as it sould be.
// This code was reused for the salvage magnet and is a mess right now as it is, it has no known issues with, I hope, but its not cleaned as it sould be.
// If you know what you are doing, fix this please to look "usable"
// - Dvir01

Expand Down
2 changes: 2 additions & 0 deletions Resources/Locale/en-US/_NF/store/uplink-catalog.ftl
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
uplink-emp-grenade-launcher-bundle-name = EMP China-Lake Bundle
uplink-emp-grenade-launcher-bundle-desc = An old China-Lake grenade launcher bundled with 8 rounds of EMP.
4 changes: 2 additions & 2 deletions Resources/Prototypes/Catalog/Fills/Boxes/ammunition.yml
Original file line number Diff line number Diff line change
Expand Up @@ -307,12 +307,12 @@
- type: entity
name: box of SMG .35 auto (emp) magazines
parent: BoxMagazine
id: BoxMagazinePistolSubMachineGunEMP
id: BoxMagazinePistolSubMachineGunEmp
description: A box full of SMG .35 auto (emp) magazines.
components:
- type: StorageFill
contents:
- id: MagazinePistolSubMachineGunEMP
- id: MagazinePistolSubMachineGunEmp
amount: 3

# Shotgun
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,8 @@
- state: rubber

- type: entity
id: MagazineBoxPistolIncendiary
parent: BaseMagazineBoxPistol
id: MagazineBoxPistolIncendiary
name: ammunition box (.35 auto incendiary)
components:
- type: BallisticAmmoProvider
Expand All @@ -112,4 +112,4 @@
map: ["enum.GunVisualLayers.Base"]
- state: mag-1
map: ["enum.GunVisualLayers.Mag"]
- state: emp
- state: emp
Original file line number Diff line number Diff line change
Expand Up @@ -66,4 +66,4 @@
parent: BaseCartridgePistol
components:
- type: CartridgeAmmo
proto: BulletPistolEmp
proto: BulletPistolEmp
Original file line number Diff line number Diff line change
Expand Up @@ -314,4 +314,4 @@
- state: rubber
map: ["enum.GunVisualLayers.Base"]
- state: mag-1
map: ["enum.GunVisualLayers.Mag"]
map: ["enum.GunVisualLayers.Mag"]
Original file line number Diff line number Diff line change
Expand Up @@ -59,4 +59,5 @@
parent: BaseBulletEmp
noSpawn: true
components:
- type: Projectile
- type: Projectile

Original file line number Diff line number Diff line change
Expand Up @@ -135,38 +135,3 @@
- type: Sprite
sprite: Objects/Weapons/Guns/Ammunition/Explosives/explosives.rsi
state: ball

- type: entity
id: GrenadeEmp
name: emp grenade
parent: BaseGrenade
components:
- type: CartridgeAmmo
proto: BulletGrenadeEmp
- type: Sprite
sprite: Objects/Weapons/Guns/Ammunition/Explosives/explosives.rsi
layers:
- state: emp
map: ["enum.AmmoVisualLayers.Base"]
- type: Appearance
- type: SpentAmmoVisuals
state: emp
suffix: false

- type: entity
id: CartridgeRocketEmp
name: PG-7VL emp
parent: BaseItem
description: A 1.5 emp warhead designed for the RPG-7 launcher. Has tubular shape.
components:
- type: Tag
tags:
- CartridgeRocket
- type: Item
size: 5
- type: CartridgeAmmo
proto: BulletRocketEmp
deleteOnSpawn: true
- type: Sprite
sprite: Objects/Weapons/Guns/Ammunition/Explosives/explosives.rsi
state: rpg-emp
Original file line number Diff line number Diff line change
Expand Up @@ -460,38 +460,3 @@
- type: Appearance
- type: StaticPrice
price: 750

- type: entity
name: emp emitter
parent: BaseWeaponBattery
id: WeaponEmpEmitter
description: Releases electromagnetic pulses that disrupt or damage many electronic devices or drain power cells.
components:
- type: Sprite
sprite: Objects/Weapons/Guns/Battery/xray.rsi
layers:
- state: base
map: ["enum.GunVisualLayers.Base"]
- state: mag-unshaded-0
map: ["enum.GunVisualLayers.MagUnshaded"]
shader: unshaded
- type: Clothing
sprite: Objects/Weapons/Guns/Battery/xray.rsi
- type: Gun
fireRate: 1
selectedMode: SemiAuto
availableModes:
- SemiAuto
soundGunshot:
path: /Audio/Weapons/Guns/Gunshots/laser3.ogg
- type: Battery
maxCharge: 1000
startingCharge: 1000
- type: ProjectileBatteryAmmoProvider
proto: ProjectileEmp
fireCost: 1000
- type: MagazineVisuals
magState: mag
steps: 5
zeroVisible: true
- type: Appearance
Original file line number Diff line number Diff line change
Expand Up @@ -814,4 +814,4 @@
- type: EmpOnTrigger
range: 2
energyConsumption: 50000
disableDuration: 30
disableDuration: 30
11 changes: 11 additions & 0 deletions Resources/Prototypes/_NF/Catalog/Fills/Backpacks/duffelbag.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
- type: entity
parent: ClothingBackpackDuffelSyndicateBundle
id: ClothingBackpackDuffelSyndicateFilledEmpGrenadeLauncher
name: China-Lake EMP bundle
description: "An old China-Lake grenade launcher bundled with 8 rounds of EMP."
components:
- type: StorageFill
contents:
- id: WeaponLauncherChinaLakeEmp
- id: GrenadeEmp
amount: 8
10 changes: 10 additions & 0 deletions Resources/Prototypes/_NF/Catalog/uplink_catalog.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
- type: listing
id: UplinkEmpGrenadeLauncherBundle
name: uplink-emp-grenade-launcher-bundle-name
description: uplink-emp-grenade-launcher-bundle-desc
icon: { sprite: /Textures/Objects/Weapons/Guns/Launchers/china_lake.rsi, state: icon }
productEntity: ClothingBackpackDuffelSyndicateFilledEmpGrenadeLauncher
cost:
Telecrystal: 25
categories:
- UplinkBundles
Empty file.
Empty file.
Empty file.
Empty file.
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# Rockets

- type: entity
id: CartridgeRocketEmp
name: PG-7VL emp
parent: BaseItem
description: A 1.5 emp warhead designed for the RPG-7 launcher. Has tubular shape.
components:
- type: Tag
tags:
- CartridgeRocket
- type: Item
size: 5
- type: CartridgeAmmo
proto: BulletRocketEmp
deleteOnSpawn: true
- type: Sprite
sprite: Objects/Weapons/Guns/Ammunition/Explosives/explosives.rsi
state: rpg-emp

# Grenades

- type: entity
id: GrenadeEmp
name: emp grenade # Chinalake EMP
parent: BaseGrenade
components:
- type: CartridgeAmmo
proto: BulletGrenadeEmp
- type: Sprite
sprite: Objects/Weapons/Guns/Ammunition/Explosives/explosives.rsi
layers:
- state: emp
map: ["enum.AmmoVisualLayers.Base"]
- type: Appearance
- type: SpentAmmoVisuals
state: emp
suffix: false
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
- type: entity
name: emp emitter
parent: BaseWeaponBattery
id: WeaponEmpEmitter
description: Releases electromagnetic pulses that disrupt or damage many electronic devices or drain power cells.
components:
- type: Sprite
sprite: Objects/Weapons/Guns/Battery/xray.rsi
layers:
- state: base
map: ["enum.GunVisualLayers.Base"]
- state: mag-unshaded-0
map: ["enum.GunVisualLayers.MagUnshaded"]
shader: unshaded
- type: Clothing
sprite: Objects/Weapons/Guns/Battery/xray.rsi
- type: Gun
fireRate: 1
selectedMode: SemiAuto
availableModes:
- SemiAuto
soundGunshot:
path: /Audio/Weapons/Guns/Gunshots/laser3.ogg
- type: Battery
maxCharge: 1000
startingCharge: 1000
- type: ProjectileBatteryAmmoProvider
proto: ProjectileEmp
fireCost: 1000
- type: MagazineVisuals
magState: mag
steps: 5
zeroVisible: true
- type: Appearance
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
- type: entity
name: china lake
parent: BaseWeaponLauncher
suffix: EMP
id: WeaponLauncherChinaLakeEmp
description: PLOOP
components:
- type: Sprite
sprite: Objects/Weapons/Guns/Launchers/china_lake.rsi
layers:
- state: icon
map: ["enum.GunVisualLayers.Base"]
- type: Clothing
sprite: Objects/Weapons/Guns/Launchers/china_lake.rsi
- type: AmmoCounter
- type: Gun
fireRate: 1
selectedMode: SemiAuto
availableModes:
- SemiAuto
soundGunshot:
path: /Audio/Weapons/Guns/Gunshots/grenade_launcher.ogg
- type: BallisticAmmoProvider
whitelist:
tags:
- Grenade
autoCycle: false
capacity: 3
proto: GrenadeEmp
soundInsert:
path: /Audio/Weapons/Guns/MagIn/batrifle_magin.ogg

- type: entity
name: RPG-7
suffix: EMP
parent: BaseWeaponLauncher
id: WeaponLauncherRocketEmp
description: A modified ancient rocket-propelled grenade launcher.
components:
- type: Sprite
sprite: Objects/Weapons/Guns/Launchers/rocket.rsi
layers:
- state: base
map: ["enum.GunVisualLayers.Base"]
- state: mag-0
map: ["enum.GunVisualLayers.Mag"]
- type: Clothing
sprite: Objects/Weapons/Guns/Launchers/rocket.rsi
- type: Gun
fireRate: 0.5
soundGunshot:
path: /Audio/Weapons/Guns/Gunshots/rpgfire.ogg
- type: BallisticAmmoProvider
whitelist:
tags:
- CartridgeRocket
proto: CartridgeRocketEmp
capacity: 1
soundInsert:
path: /Audio/Weapons/Guns/MagIn/batrifle_magin.ogg
- type: MagazineVisuals
magState: mag
steps: 2
zeroVisible: false
- type: Appearance
Empty file.

0 comments on commit ce54ec6

Please sign in to comment.