Incediary Shells (#6208)

Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
This commit is contained in:
ScalyChimp
2022-01-30 13:44:45 +00:00
committed by GitHub
parent 45c0862394
commit 004c678853
10 changed files with 107 additions and 5 deletions

View File

@@ -292,6 +292,7 @@ namespace Content.Client.Entry
"MonkeyAccent", "MonkeyAccent",
"ReplacementAccent", "ReplacementAccent",
"ResistLocker", "ResistLocker",
"IgniteOnCollide",
"SpawnArtifact", "SpawnArtifact",
"TelepathicArtifact", "TelepathicArtifact",
"ArtifactGasTrigger", "ArtifactGasTrigger",

View File

@@ -0,0 +1,19 @@
using Robust.Shared.GameObjects;
using Robust.Shared.Serialization.Manager.Attributes;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Content.Server.Atmos.Components
{
[RegisterComponent]
public class IgniteOnCollideComponent : Component
{
public override string Name => "IgniteOnCollide";
[DataField("fireStacks")]
public float FireStacks { get; set; }
}
}

View File

@@ -49,6 +49,15 @@ namespace Content.Server.Atmos.EntitySystems
SubscribeLocalEvent<FlammableComponent, StartCollideEvent>(OnCollideEvent); SubscribeLocalEvent<FlammableComponent, StartCollideEvent>(OnCollideEvent);
SubscribeLocalEvent<FlammableComponent, IsHotEvent>(OnIsHotEvent); SubscribeLocalEvent<FlammableComponent, IsHotEvent>(OnIsHotEvent);
SubscribeLocalEvent<FlammableComponent, TileFireEvent>(OnTileFireEvent); SubscribeLocalEvent<FlammableComponent, TileFireEvent>(OnTileFireEvent);
SubscribeLocalEvent<IgniteOnCollideComponent, StartCollideEvent>(IgniteOnCollide);
}
private void IgniteOnCollide(EntityUid uid, IgniteOnCollideComponent component, StartCollideEvent args)
{
var otherfixture = args.OtherFixture.Body.Owner;
if (EntityManager.TryGetComponent(otherfixture, out FlammableComponent flammable))
flammable.FireStacks += component.FireStacks;
Ignite(otherfixture, flammable);
} }
private void OnInteractUsingEvent(EntityUid uid, FlammableComponent flammable, InteractUsingEvent args) private void OnInteractUsingEvent(EntityUid uid, FlammableComponent flammable, InteractUsingEvent args)

View File

@@ -49,6 +49,18 @@
projectilesFired: 4 projectilesFired: 4
ammoSpread: 10 ammoSpread: 10
- type: entity
id: ShellShotgunFlare
name: shell (.50 flare)
parent: ShellShotgunBase
components:
- type: Sprite
sprite: Objects/Weapons/Guns/Ammunition/Casings/shotgun_shell_flare.rsi
- type: Ammo
projectile: PelletShotgunFlare
projectilesFired: 1
ammoSpread: 0
- type: entity - type: entity
id: ShellShotgun id: ShellShotgun
name: shell (.50) name: shell (.50)
@@ -77,7 +89,9 @@
- type: Sprite - type: Sprite
sprite: Objects/Weapons/Guns/Ammunition/Casings/shotgun_shell_incendiary.rsi sprite: Objects/Weapons/Guns/Ammunition/Casings/shotgun_shell_incendiary.rsi
- type: Ammo - type: Ammo
projectile: PelletShotgun projectile: PelletShotgunIncendiary
projectilesFired: 6
ammoSpread: 125
- type: entity - type: entity
id: ShellShotgunPractice id: ShellShotgunPractice

View File

@@ -64,12 +64,19 @@
parent: BulletBase parent: BulletBase
components: components:
- type: Sprite - type: Sprite
sprite: Objects/Weapons/Guns/Projectiles/buckshot.rsi sprite: Objects/Weapons/Guns/Projectiles/flare_buckshot.rsi
state: base state: base
- type: Projectile - type: Projectile
damage: damage:
types: groups:
Blunt: 13 Burn: 10
- type: PointLight
enabled: true
color: "#ff4300"
radius: 2.0
energy: 7.0
- type: IgniteOnCollide
fireStacks: 1
- type: entity - type: entity
id: PelletShotgunPractice id: PelletShotgunPractice
@@ -110,3 +117,24 @@
transferAmount: 15 transferAmount: 15
- type: InjectableSolution - type: InjectableSolution
solution: ammo solution: ammo
- type: entity
id: PelletShotgunFlare
name: pellet (.50 flare)
abstract: true
parent: BulletBase
components:
- type: Sprite
sprite: Objects/Weapons/Guns/Projectiles/flare_buckshot.rsi
state: base
- type: Projectile
damage:
groups:
Burn: 20
- type: PointLight
enabled: true
color: "#FF8080"
radius: 15.0
energy: 9.0
- type: IgniteOnCollide
fireStacks: 4

Binary file not shown.

After

Width:  |  Height:  |  Size: 363 B

View File

@@ -0,0 +1,17 @@
{
"version": 1,
"size": {
"x": 32,
"y": 32
},
"license": "CC-BY-SA-3.0",
"copyright": "https://github.com/discordia-space/CEV-Eris/raw/e1d495c3faf4642b6ec1c4be8acc7cd5bc51d785/icons/obj/ammo.dmi",
"states": [
{
"name": "base"
},
{
"name": "spent"
}
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 356 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 506 B

View File

@@ -0,0 +1,14 @@
{
"version": 1,
"license": "CC-BY-SA-3.0",
"copyright": "Taken from cev-eris at https://github.com/discordia-space/CEV-Eris/raw/2acc4d34a894dbcc9dbf3779b696ddf296aa2c56/icons/obj/projectiles.dmi",
"size": {
"x": 32,
"y": 32
},
"states": [
{
"name": "base"
}
]
}