Skip to content

Commit

Permalink
Merge pull request #32 from 778b/plasma-weapons
Browse files Browse the repository at this point in the history
Plasma weapons
  • Loading branch information
778b authored Feb 1, 2024
2 parents 9b23ae4 + c36928b commit 0a50177
Show file tree
Hide file tree
Showing 39 changed files with 419 additions and 200 deletions.
Binary file not shown.
4 changes: 2 additions & 2 deletions Resources/Maps/deterrent.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42417,7 +42417,7 @@ entities:
- type: Transform
pos: 0.4962628,0.63428205
parent: 2
- proto: TSWeaponLaserMachineGunP
- proto: TSWeaponPlasmaMachineGun
entities:
- uid: 2158
components:
Expand All @@ -42429,7 +42429,7 @@ entities:
- type: Transform
pos: 18.52543,13.541773
parent: 2
- proto: TSWeaponLaserRifle
- proto: WeaponPlasmaRifle
entities:
- uid: 2140
components:
Expand Down
10 changes: 9 additions & 1 deletion Resources/Prototypes/Entities/Structures/Power/chargers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,8 @@
blacklist:
tags:
- PotatoBattery

- PlasmaMagazine

- type: entity
parent: [ BaseItemRecharger, ConstructibleMachine ]
id: PowerCageRecharger
Expand Down Expand Up @@ -167,6 +168,9 @@
- HitscanBatteryAmmoProvider
- ProjectileBatteryAmmoProvider
- Stunbaton
blacklist:
tags:
- PlasmaMagazine

- type: entity
parent: BaseItemRecharger
Expand All @@ -193,6 +197,7 @@
blacklist:
tags:
- PotatoBattery
- PlasmaMagazine

- type: entity
parent: BaseItemRecharger
Expand All @@ -219,6 +224,9 @@
- HitscanBatteryAmmoProvider
- ProjectileBatteryAmmoProvider
- Stunbaton
blacklist:
tags:
- PlasmaMagazine

- type: entity
parent: BaseRecharger
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,99 @@
- type: entity
id: MagazinePlasmaRed
parent: BaseItem
name: light plasma mag
suffix: Red
components:
- type: Tag
tags:
- PlasmaMagazine
- LightPlasmaMagazine
- type: Item
size: Small
sprite: TS/Objects/Weapons/Ammunition/Magazine/Plasma/light_plasma_mag.rsi
- type: Sprite
sprite: TS/Objects/Weapons/Ammunition/Magazine/Plasma/light_plasma_mag.rsi
state: base
- type: ProjectileBatteryAmmoProvider
proto: RedPlasmaBullet
fireCost: 1
- type: Battery
maxCharge: 100
startingCharge: 100
- type: Appearance

- type: entity
id: MagazinePlasmaBlue
parent: MagazinePlasmaRed
name: light plasma mag
suffix: Blue
components:
- type: ProjectileBatteryAmmoProvider
proto: BluePlasmaBullet
fireCost: 1
- type: Battery
maxCharge: 75
startingCharge: 75

- type: entity
id: MagazinePlasmaGreen
parent: MagazinePlasmaRed
name: light plasma mag
suffix: Green
components:
- type: ProjectileBatteryAmmoProvider
proto: GreenPlasmaBullet
fireCost: 1
- type: Battery
maxCharge: 50
startingCharge: 50

- type: entity
id: HeavyMagazinePlasmaRed
parent: BaseItem
name: heavy plasma mag
suffix: Red
components:
- type: Tag
tags:
- PlasmaMagazine
- HeavyPlasmaMagazine
- type: Item
size: Large
sprite: TS/Objects/Weapons/Ammunition/Magazine/Plasma/heavy_plasma_mag.rsi
- type: Sprite
sprite: TS/Objects/Weapons/Ammunition/Magazine/Plasma/heavy_plasma_mag.rsi
state: base
- type: ProjectileBatteryAmmoProvider
proto: RedPlasmaBullet
fireCost: 1
- type: Battery
maxCharge: 350
startingCharge: 350
- type: Appearance

- type: entity
id: HeavyMagazinePlasmaBlue
parent: HeavyMagazinePlasmaRed
name: heavy plasma mag
suffix: Blue
components:
- type: ProjectileBatteryAmmoProvider
proto: BluePlasmaBullet
fireCost: 1
- type: Battery
maxCharge: 240
startingCharge: 240

- type: entity
id: HeavyMagazinePlasmaGreen
parent: HeavyMagazinePlasmaRed
name: heavy plasma mag
suffix: Green
components:
- type: ProjectileBatteryAmmoProvider
proto: GreenPlasmaBullet
fireCost: 1
- type: Battery
maxCharge: 160
startingCharge: 160
138 changes: 66 additions & 72 deletions Resources/Prototypes/TS/Entities/Objects/Weapons/TroopWeapon.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,24 @@
- type: entity
name: ALR-01
parent: BaseWeaponBattery
id: TSWeaponLaserRifle
description: Combat automatic laser rifle, version 1.
name: APR-01
parent: BaseWeaponPowerCell
id: WeaponPlasmaRifle
description: Combat automatic plasma rifle, version 1.
components:
- type: Sprite
sprite: TS/Objects/Weapons/Guns/Rifles/alr_01.rsi
sprite: TS/Objects/Weapons/Guns/Rifles/apr_01.rsi
layers:
- state: base
map: ["enum.GunVisualLayers.Base"]
- state: mag-unshaded-4
map: ["enum.GunVisualLayers.MagUnshaded"]
shader: unshaded
- type: Wieldable
- type: AmmoCounter
- type: GunWieldBonus
minAngle: -20
maxAngle: -35
- type: Clothing
sprite: TS/Objects/Weapons/Guns/Rifles/alr_01.rsi
sprite: TS/Objects/Weapons/Guns/Rifles/apr_01.rsi
quickEquip: false
slots:
- Back
Expand All @@ -32,24 +33,44 @@
maxAngle: 35
fireRate: 3
soundGunshot:
path: /Audio/Weapons/Guns/Gunshots/laser3.ogg
- type: HitscanBatteryAmmoProvider
proto: RedMediumLaser
fireCost: 50
- type: Battery
maxCharge: 5000
startingCharge: 5000
path: /Audio/Weapons/Guns/Gunshots/warfare-plasma.ogg
- type: ContainerContainer
containers:
gun_magazine: !type:ContainerSlot
power_magazine: !type:ContainerSlot
- type: MagazineAmmoProvider
- type: MagazineVisuals
magState: mag
steps: 4
zeroVisible: false
- type: ItemSlots
slots:
gun_magazine:
name: Magazine
insertSound: /Audio/Weapons/Guns/MagIn/batrifle_magin.ogg
ejectSound: /Audio/Weapons/Guns/MagOut/batrifle_magout.ogg
whitelist:
tags:
- LightPlasmaMagazine
power_magazine:
name: Power
startingItem: PowerCellSmall
insertSound: /Audio/Weapons/Guns/MagIn/batrifle_magin.ogg
ejectSound: /Audio/Weapons/Guns/MagOut/batrifle_magout.ogg
whitelist:
components:
- PowerCell
- type: StaticPrice
price: 1500

- type: entity
name: LMGP
parent: BaseWeaponBattery
id: TSWeaponLaserMachineGunP
description: Laser machine gun Perusheva
name: PMGP
parent: BaseWeaponPowerCell
id: TSWeaponPlasmaMachineGun
description: Plasma machine gun Petrusheva
components:
- type: Sprite
sprite: TS/Objects/Weapons/Guns/Rifles/lmgp.rsi
sprite: TS/Objects/Weapons/Guns/Rifles/pmgp.rsi
layers:
- state: base
map: ["enum.GunVisualLayers.Base"]
Expand All @@ -61,19 +82,20 @@
minAngle: -20
maxAngle: -20
- type: Clothing
sprite: TS/Objects/Weapons/Guns/Rifles/lmgp.rsi
sprite: TS/Objects/Weapons/Guns/Rifles/pmgp.rsi
quickEquip: false
slots:
- Back
- suitStorage
- type: MagazineVisuals
magState: mag
steps: 4
steps: 3
zeroVisible: false
- type: ClothingSpeedModifier
walkModifier: 0.75
sprintModifier: 0.7
- type: HeldSpeedModifier
- type: AmmoCounter
- type: Gun
availableModes:
- FullAuto
Expand All @@ -83,57 +105,29 @@
maxAngle: 50
fireRate: 7
soundGunshot:
path: /Audio/Weapons/Guns/Gunshots/laser3.ogg
- type: HitscanBatteryAmmoProvider
proto: RedLightLaser
fireCost: 25
- type: Battery
maxCharge: 15000
startingCharge: 15000
- type: StaticPrice
price: 2500


- type: entity
name: ALR-Practice
parent: BaseWeaponBattery
id: TSWeaponLaserRiflePractice
description: Practice automatic laser rifle, prototype of ALR-01.
components:
- type: Sprite
sprite: TS/Objects/Weapons/Guns/Rifles/alr_01.rsi
layers:
- state: base
map: ["enum.GunVisualLayers.Base"]
- state: mag-unshaded-4
map: ["enum.GunVisualLayers.MagUnshaded"]
shader: unshaded
- type: Wieldable
- type: GunWieldBonus
minAngle: -20
maxAngle: -35
- type: Clothing
sprite: TS/Objects/Weapons/Guns/Rifles/alr_01.rsi
quickEquip: false
path: /Audio/Weapons/Guns/Gunshots/warfare-plasma.ogg
- type: ContainerContainer
containers:
gun_magazine: !type:ContainerSlot
power_magazine: !type:ContainerSlot
- type: MagazineAmmoProvider
- type: ItemSlots
slots:
- Back
- suitStorage
- type: Gun
availableModes:
- SemiAuto
- FullAuto
selectedMode: FullAuto
angleDecay: 10
minAngle: 20
maxAngle: 35
fireRate: 3
soundGunshot:
path: /Audio/Weapons/Guns/Gunshots/laser3.ogg
- type: HitscanBatteryAmmoProvider
proto: RedLaserPractice
fireCost: 10
- type: Battery
maxCharge: 1000
startingCharge: 1000
gun_magazine:
name: Magazine
insertSound: /Audio/Weapons/Guns/MagIn/batrifle_magin.ogg
ejectSound: /Audio/Weapons/Guns/MagOut/batrifle_magout.ogg
whitelist:
tags:
- HeavyPlasmaMagazine
- LightPlasmaMagazine
power_magazine:
name: Power
startingItem: PowerCellSmall
insertSound: /Audio/Weapons/Guns/MagIn/batrifle_magin.ogg
ejectSound: /Audio/Weapons/Guns/MagOut/batrifle_magout.ogg
whitelist:
components:
- PowerCell
- type: StaticPrice
price: 500
price: 2500
44 changes: 44 additions & 0 deletions Resources/Prototypes/TS/Entities/Objects/Weapons/projectiles.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
- type: entity
id: BluePlasmaBullet
parent: BaseBullet
noSpawn: true
components:
- type: Sprite
sprite: TS/Objects/Weapons/Guns/Projectiles/plasma.rsi
layers:
- state: blue
- type: Projectile
damage:
types:
Heat: 12
Brute: 7

- type: entity
id: GreenPlasmaBullet
parent: BaseBullet
noSpawn: true
components:
- type: Sprite
sprite: TS/Objects/Weapons/Guns/Projectiles/plasma.rsi
layers:
- state: green
- type: Projectile
damage:
types:
Heat: 19
Brute: 11

- type: entity
id: RedPlasmaBullet
parent: BaseBullet
noSpawn: true
components:
- type: Sprite
sprite: TS/Objects/Weapons/Guns/Projectiles/plasma.rsi
layers:
- state: red
- type: Projectile
damage:
types:
Heat: 5
Brute: 4
Loading

0 comments on commit 0a50177

Please sign in to comment.