diff --git a/Content.Client/Entry/IgnoredComponents.cs b/Content.Client/Entry/IgnoredComponents.cs index aa99a0c508..52bf3014a7 100644 --- a/Content.Client/Entry/IgnoredComponents.cs +++ b/Content.Client/Entry/IgnoredComponents.cs @@ -179,8 +179,6 @@ namespace Content.Client.Entry "StorageCounter", "SpaceVillainArcade", "Flammable", - "CreamPie", - "CreamPied", "Smoking", "Matchstick", "Matchbox", diff --git a/Content.Client/Nutrition/EntitySystems/CreamPiedSystem.cs b/Content.Client/Nutrition/EntitySystems/CreamPiedSystem.cs new file mode 100644 index 0000000000..71b9986ed0 --- /dev/null +++ b/Content.Client/Nutrition/EntitySystems/CreamPiedSystem.cs @@ -0,0 +1,10 @@ +using Content.Shared.Nutrition.EntitySystems; +using JetBrains.Annotations; + +namespace Content.Client.Nutrition.EntitySystems +{ + [UsedImplicitly] + public class CreamPiedSystem : SharedCreamPieSystem + { + } +} diff --git a/Content.Server/Chemistry/ReagentEntityReactions/WashCreamPieReaction.cs b/Content.Server/Chemistry/ReagentEntityReactions/WashCreamPieReaction.cs index 8005384562..51794ebb7c 100644 --- a/Content.Server/Chemistry/ReagentEntityReactions/WashCreamPieReaction.cs +++ b/Content.Server/Chemistry/ReagentEntityReactions/WashCreamPieReaction.cs @@ -1,7 +1,9 @@ using System.Collections.Generic; using Content.Server.Nutrition.Components; +using Content.Server.Nutrition.EntitySystems; using Content.Shared.Chemistry.Reagent; using Content.Shared.Chemistry.Solution; +using Content.Shared.Nutrition.Components; using JetBrains.Annotations; using Robust.Shared.GameObjects; using Robust.Shared.Serialization.Manager.Attributes; @@ -20,7 +22,7 @@ namespace Content.Server.Chemistry.ReagentEntityReactions { if (!entity.TryGetComponent(out CreamPiedComponent? creamPied) || !_reagents.Contains(reagent.ID)) return; - creamPied.Wash(); + EntitySystem.Get().SetCreamPied(entity.Uid, creamPied, false); } } } diff --git a/Content.Server/Damage/Components/DamageOtherOnHitComponent.cs b/Content.Server/Damage/Components/DamageOtherOnHitComponent.cs index 1e110f414c..f0e008f6f1 100644 --- a/Content.Server/Damage/Components/DamageOtherOnHitComponent.cs +++ b/Content.Server/Damage/Components/DamageOtherOnHitComponent.cs @@ -1,28 +1,23 @@ using Content.Shared.Damage; -using Content.Shared.Damage.Components; -using Content.Shared.Throwing; +using Robust.Shared.Analyzers; using Robust.Shared.GameObjects; using Robust.Shared.Serialization.Manager.Attributes; namespace Content.Server.Damage.Components { + [Friend(typeof(DamageOtherOnHitSystem))] [RegisterComponent] - public class DamageOtherOnHitComponent : Component, IThrowCollide + public class DamageOtherOnHitComponent : Component { public override string Name => "DamageOtherOnHit"; [DataField("damageType")] - private DamageType _damageType = DamageType.Blunt; + public DamageType DamageType { get; } = DamageType.Blunt; + [DataField("amount")] - private int _amount = 1; + public int Amount { get; } = 1; + [DataField("ignoreResistances")] - private bool _ignoreResistances; - - void IThrowCollide.DoHit(ThrowCollideEventArgs eventArgs) - { - if (!eventArgs.Target.TryGetComponent(out IDamageableComponent? damageable)) return; - - damageable.ChangeDamage(_damageType, _amount, _ignoreResistances, eventArgs.User); - } + public bool IgnoreResistances { get; } = false; } } diff --git a/Content.Server/Damage/DamageOtherOnHitSystem.cs b/Content.Server/Damage/DamageOtherOnHitSystem.cs new file mode 100644 index 0000000000..e70be630c1 --- /dev/null +++ b/Content.Server/Damage/DamageOtherOnHitSystem.cs @@ -0,0 +1,23 @@ +using Content.Server.Damage.Components; +using Content.Shared.Damage.Components; +using Content.Shared.Throwing; +using Robust.Shared.GameObjects; + +namespace Content.Server.Damage +{ + public class DamageOtherOnHitSystem : EntitySystem + { + public override void Initialize() + { + SubscribeLocalEvent(OnDoHit); + } + + private void OnDoHit(EntityUid uid, DamageOtherOnHitComponent component, ThrowDoHitEvent args) + { + if (!args.Target.TryGetComponent(out IDamageableComponent? damageable)) + return; + + damageable.ChangeDamage(component.DamageType, component.Amount, component.IgnoreResistances, args.User); + } + } +} diff --git a/Content.Server/Damage/RejuvenateVerb.cs b/Content.Server/Damage/RejuvenateVerb.cs index 12cfa57497..9447d2dfd3 100644 --- a/Content.Server/Damage/RejuvenateVerb.cs +++ b/Content.Server/Damage/RejuvenateVerb.cs @@ -1,8 +1,10 @@ using Content.Server.Atmos.Components; using Content.Server.Nutrition.Components; +using Content.Server.Nutrition.EntitySystems; using Content.Server.Stunnable.Components; using Content.Shared.Damage.Components; using Content.Shared.MobState; +using Content.Shared.Nutrition.Components; using Content.Shared.Verbs; using Robust.Server.Console; using Robust.Server.GameObjects; @@ -89,7 +91,7 @@ namespace Content.Server.Damage if (target.TryGetComponent(out CreamPiedComponent? creamPied)) { - creamPied.Wash(); + EntitySystem.Get().SetCreamPied(target.Uid, creamPied, false); } } } diff --git a/Content.Server/Disposal/Unit/EntitySystems/DisposalUnitSystem.cs b/Content.Server/Disposal/Unit/EntitySystems/DisposalUnitSystem.cs index 22505ac3fc..9cdbc62f63 100644 --- a/Content.Server/Disposal/Unit/EntitySystems/DisposalUnitSystem.cs +++ b/Content.Server/Disposal/Unit/EntitySystems/DisposalUnitSystem.cs @@ -52,7 +52,7 @@ namespace Content.Server.Disposal.Unit.EntitySystems SubscribeLocalEvent(HandleDisposalInit); SubscribeLocalEvent(HandleDisposalShutdown); - SubscribeLocalEvent(HandleThrowCollide); + SubscribeLocalEvent(HandleThrowCollide); // Interactions SubscribeLocalEvent(HandleActivate); @@ -144,7 +144,7 @@ namespace Content.Server.Disposal.Unit.EntitySystems /// /// Thrown items have a chance of bouncing off the unit and not going in. /// - private void HandleThrowCollide(EntityUid uid, DisposalUnitComponent component, ThrowCollideEvent args) + private void HandleThrowCollide(EntityUid uid, DisposalUnitComponent component, ThrowHitByEvent args) { if (!CanInsert(component, args.Thrown) || _robustRandom.NextDouble() > 0.75 || diff --git a/Content.Server/Nutrition/Components/CreamPieComponent.cs b/Content.Server/Nutrition/Components/CreamPieComponent.cs deleted file mode 100644 index 2cf0349582..0000000000 --- a/Content.Server/Nutrition/Components/CreamPieComponent.cs +++ /dev/null @@ -1,53 +0,0 @@ -using Content.Server.Chemistry.Components; -using Content.Server.Fluids.Components; -using Content.Shared.Audio; -using Content.Shared.Sound; -using Content.Shared.Throwing; -using Robust.Shared.Audio; -using Robust.Shared.GameObjects; -using Robust.Shared.Player; -using Robust.Shared.Serialization.Manager.Attributes; -using Robust.Shared.ViewVariables; - -namespace Content.Server.Nutrition.Components -{ - [RegisterComponent] - public class CreamPieComponent : Component, ILand, IThrowCollide - { - public override string Name => "CreamPie"; - - [ViewVariables(VVAccess.ReadWrite)] - [DataField("paralyzeTime")] - public float ParalyzeTime { get; set; } = 1f; - - [DataField("sound")] - private SoundSpecifier _sound = new SoundCollectionSpecifier("desecration"); - - public void PlaySound() - { - SoundSystem.Play(Filter.Pvs(Owner), _sound.GetSound(), Owner, AudioHelpers.WithVariation(0.125f)); - } - - void IThrowCollide.DoHit(ThrowCollideEventArgs eventArgs) - { - Splat(); - } - - void ILand.Land(LandEventArgs eventArgs) - { - Splat(); - } - - public void Splat() - { - PlaySound(); - - if (Owner.TryGetComponent(out SolutionContainerComponent? solution)) - { - solution.Solution.SpillAt(Owner, "PuddleSmear", false); - } - - Owner.QueueDelete(); - } - } -} diff --git a/Content.Server/Nutrition/Components/CreamPiedComponent.cs b/Content.Server/Nutrition/Components/CreamPiedComponent.cs deleted file mode 100644 index 61f83e7c25..0000000000 --- a/Content.Server/Nutrition/Components/CreamPiedComponent.cs +++ /dev/null @@ -1,55 +0,0 @@ -using Content.Server.Notification; -using Content.Server.Stunnable.Components; -using Content.Shared.Notification; -using Content.Shared.Notification.Managers; -using Content.Shared.Nutrition.Components; -using Content.Shared.Throwing; -using Robust.Server.GameObjects; -using Robust.Shared.GameObjects; -using Robust.Shared.Localization; -using Robust.Shared.ViewVariables; - -namespace Content.Server.Nutrition.Components -{ - [RegisterComponent] - public class CreamPiedComponent : SharedCreamPiedComponent, IThrowCollide - { - private bool _creamPied; - - [ViewVariables] - public bool CreamPied - { - get => _creamPied; - private set - { - if (value == _creamPied) return; - - _creamPied = value; - if (Owner.TryGetComponent(out AppearanceComponent? appearance)) - { - appearance.SetData(CreamPiedVisuals.Creamed, CreamPied); - } - } - } - - public void Wash() - { - if(CreamPied) - CreamPied = false; - } - - void IThrowCollide.HitBy(ThrowCollideEventArgs eventArgs) - { - if (eventArgs.Thrown.Deleted || !eventArgs.Thrown.TryGetComponent(out CreamPieComponent? creamPie)) return; - - CreamPied = true; - Owner.PopupMessage(Loc.GetString("cream-pied-component-on-hit-by-message",("thrower", eventArgs.Thrown))); - Owner.PopupMessageOtherClients(Loc.GetString("cream-pied-component-on-hit-by-message-others", ("owner", Owner),("thrower", eventArgs.Thrown))); - - if (Owner.TryGetComponent(out StunnableComponent? stun)) - { - stun.Paralyze(creamPie.ParalyzeTime); - } - } - } -} diff --git a/Content.Server/Nutrition/EntitySystems/CreamPieSystem.cs b/Content.Server/Nutrition/EntitySystems/CreamPieSystem.cs new file mode 100644 index 0000000000..7d47fdb065 --- /dev/null +++ b/Content.Server/Nutrition/EntitySystems/CreamPieSystem.cs @@ -0,0 +1,36 @@ +using Content.Server.Chemistry.Components; +using Content.Server.Fluids.Components; +using Content.Server.Notification; +using Content.Shared.Audio; +using Content.Shared.Notification.Managers; +using Content.Shared.Nutrition.Components; +using Content.Shared.Nutrition.EntitySystems; +using Content.Shared.Throwing; +using JetBrains.Annotations; +using Robust.Shared.Audio; +using Robust.Shared.GameObjects; +using Robust.Shared.Localization; +using Robust.Shared.Player; + +namespace Content.Server.Nutrition.EntitySystems +{ + [UsedImplicitly] + public class CreamPieSystem : SharedCreamPieSystem + { + protected override void SplattedCreamPie(EntityUid uid, CreamPieComponent creamPie) + { + SoundSystem.Play(Filter.Pvs(creamPie.Owner), creamPie.Sound.GetSound(), creamPie.Owner, AudioHelpers.WithVariation(0.125f)); + + if (ComponentManager.TryGetComponent(uid, out SolutionContainerComponent? solution)) + { + solution.Solution.SpillAt(creamPie.Owner, "PuddleSmear", false); + } + } + + protected override void CreamedEntity(EntityUid uid, CreamPiedComponent creamPied, ThrowHitByEvent args) + { + creamPied.Owner.PopupMessage(Loc.GetString("cream-pied-component-on-hit-by-message",("thrower", args.Thrown))); + creamPied.Owner.PopupMessageOtherClients(Loc.GetString("cream-pied-component-on-hit-by-message-others", ("owner", creamPied.Owner),("thrower", args.Thrown))); + } + } +} diff --git a/Content.Server/Stunnable/StunbatonSystem.cs b/Content.Server/Stunnable/StunbatonSystem.cs index 38efd3e26f..4bd2547d15 100644 --- a/Content.Server/Stunnable/StunbatonSystem.cs +++ b/Content.Server/Stunnable/StunbatonSystem.cs @@ -31,7 +31,7 @@ namespace Content.Server.Stunnable SubscribeLocalEvent(OnMeleeHit); SubscribeLocalEvent(OnMeleeInteract); SubscribeLocalEvent(OnUseInHand); - SubscribeLocalEvent(OnThrowCollide); + SubscribeLocalEvent(OnThrowCollide); SubscribeLocalEvent(OnPowerCellChanged); SubscribeLocalEvent(OnInteractUsing); SubscribeLocalEvent(OnExamined); @@ -81,7 +81,7 @@ namespace Content.Server.Stunnable } } - private void OnThrowCollide(EntityUid uid, StunbatonComponent comp, ThrowCollideEvent args) + private void OnThrowCollide(EntityUid uid, StunbatonComponent comp, ThrowDoHitEvent args) { if (!ComponentManager.TryGetComponent(uid, out var slot)) return; if (!comp.Activated || slot.Cell == null || !slot.Cell.TryUseCharge(comp.EnergyPerUse)) return; diff --git a/Content.Shared/Nutrition/Components/CreamPieComponent.cs b/Content.Shared/Nutrition/Components/CreamPieComponent.cs new file mode 100644 index 0000000000..b21acc640d --- /dev/null +++ b/Content.Shared/Nutrition/Components/CreamPieComponent.cs @@ -0,0 +1,27 @@ +using Content.Shared.Nutrition.EntitySystems; +using Content.Shared.Sound; +using Robust.Shared.Analyzers; +using Robust.Shared.GameObjects; +using Robust.Shared.Serialization.Manager.Attributes; +using Robust.Shared.ViewVariables; + +namespace Content.Shared.Nutrition.Components +{ + [Friend(typeof(SharedCreamPieSystem))] + [RegisterComponent] + public class CreamPieComponent : Component + { + public override string Name => "CreamPie"; + + [ViewVariables] + [DataField("paralyzeTime")] + public float ParalyzeTime { get; } = 1f; + + [ViewVariables] + [DataField("sound")] + public SoundSpecifier Sound { get; } = new SoundCollectionSpecifier("desecration"); + + [ViewVariables] + public bool Splatted { get; set; } = false; + } +} diff --git a/Content.Shared/Nutrition/Components/CreamPiedComponent.cs b/Content.Shared/Nutrition/Components/CreamPiedComponent.cs new file mode 100644 index 0000000000..4b20476c77 --- /dev/null +++ b/Content.Shared/Nutrition/Components/CreamPiedComponent.cs @@ -0,0 +1,25 @@ +using System; +using Content.Shared.Nutrition.EntitySystems; +using Robust.Shared.Analyzers; +using Robust.Shared.GameObjects; +using Robust.Shared.Serialization; +using Robust.Shared.ViewVariables; + +namespace Content.Shared.Nutrition.Components +{ + [Friend(typeof(SharedCreamPieSystem))] + [RegisterComponent] + public class CreamPiedComponent : Component + { + public override string Name => "CreamPied"; + + [ViewVariables] + public bool CreamPied { get; set; } = false; + } + + [Serializable, NetSerializable] + public enum CreamPiedVisuals + { + Creamed, + } +} diff --git a/Content.Shared/Nutrition/Components/SharedCreamPiedComponent.cs b/Content.Shared/Nutrition/Components/SharedCreamPiedComponent.cs deleted file mode 100644 index b599257de0..0000000000 --- a/Content.Shared/Nutrition/Components/SharedCreamPiedComponent.cs +++ /dev/null @@ -1,17 +0,0 @@ -using System; -using Robust.Shared.GameObjects; -using Robust.Shared.Serialization; - -namespace Content.Shared.Nutrition.Components -{ - public class SharedCreamPiedComponent : Component - { - public override string Name => "CreamPied"; - } - - [Serializable, NetSerializable] - public enum CreamPiedVisuals - { - Creamed, - } -} diff --git a/Content.Shared/Nutrition/EntitySystems/SharedCreamPieSystem.cs b/Content.Shared/Nutrition/EntitySystems/SharedCreamPieSystem.cs new file mode 100644 index 0000000000..42abb1c66c --- /dev/null +++ b/Content.Shared/Nutrition/EntitySystems/SharedCreamPieSystem.cs @@ -0,0 +1,75 @@ +using Content.Shared.Nutrition.Components; +using Content.Shared.Stunnable; +using Content.Shared.Throwing; +using JetBrains.Annotations; +using Robust.Shared.GameObjects; + +namespace Content.Shared.Nutrition.EntitySystems +{ + [UsedImplicitly] + public abstract class SharedCreamPieSystem : EntitySystem + { + public override void Initialize() + { + base.Initialize(); + + SubscribeLocalEvent(OnCreamPieHit); + SubscribeLocalEvent(OnCreamPieLand); + SubscribeLocalEvent(OnCreamPiedHitBy); + } + + public void SplatCreamPie(EntityUid uid, CreamPieComponent creamPie) + { + // Already splatted! Do nothing. + if (creamPie.Splatted) + return; + + creamPie.Splatted = true; + + SplattedCreamPie(uid, creamPie); + + EntityManager.QueueDeleteEntity(uid); + } + + protected virtual void SplattedCreamPie(EntityUid uid, CreamPieComponent creamPie) {} + + public void SetCreamPied(EntityUid uid, CreamPiedComponent creamPied, bool value) + { + if (value == creamPied.CreamPied) + return; + + creamPied.CreamPied = value; + + if (ComponentManager.TryGetComponent(uid, out SharedAppearanceComponent? appearance)) + { + appearance.SetData(CreamPiedVisuals.Creamed, value); + } + } + + private void OnCreamPieLand(EntityUid uid, CreamPieComponent component, LandEvent args) + { + SplatCreamPie(uid, component); + } + + private void OnCreamPieHit(EntityUid uid, CreamPieComponent component, ThrowDoHitEvent args) + { + SplatCreamPie(uid, component); + } + + private void OnCreamPiedHitBy(EntityUid uid, CreamPiedComponent creamPied, ThrowHitByEvent args) + { + if (args.Thrown.Deleted || !args.Thrown.TryGetComponent(out CreamPieComponent? creamPie)) return; + + SetCreamPied(uid, creamPied, true); + + CreamedEntity(uid, creamPied, args); + + if (ComponentManager.TryGetComponent(uid, out SharedStunnableComponent? stun)) + { + stun.Paralyze(creamPie.ParalyzeTime); + } + } + + protected virtual void CreamedEntity(EntityUid uid, CreamPiedComponent creamPied, ThrowHitByEvent args) {} + } +} diff --git a/Content.Shared/Throwing/IThrowCollide.cs b/Content.Shared/Throwing/IThrowCollide.cs deleted file mode 100644 index ed5903029d..0000000000 --- a/Content.Shared/Throwing/IThrowCollide.cs +++ /dev/null @@ -1,63 +0,0 @@ -using System; -using Robust.Shared.Analyzers; -using Robust.Shared.GameObjects; - -namespace Content.Shared.Throwing -{ - [RequiresExplicitImplementation] - public interface IThrowCollide - { - void HitBy(ThrowCollideEventArgs eventArgs) {} - void DoHit(ThrowCollideEventArgs eventArgs) {} - } - - public class ThrowCollideEventArgs : EventArgs - { - /// - /// The entity that threw and hit . - /// - public IEntity? User { get; } - - /// - /// The entity thrown by that hit - /// - public IEntity Thrown { get; } - - /// - /// The entity hit with by - /// - public IEntity Target { get; } - - public ThrowCollideEventArgs(IEntity? user, IEntity thrown, IEntity target) - { - User = user; - Thrown = thrown; - Target = target; - } - } - - public class ThrowCollideEvent : HandledEntityEventArgs - { - /// - /// The entity that threw . - /// - public IEntity? User { get; } - - /// - /// The entity thrown by that hit - /// - public IEntity Thrown { get; } - - /// - /// The entity hit with by - /// - public IEntity Target { get; } - - public ThrowCollideEvent(IEntity? user, IEntity thrown, IEntity target) - { - User = user; - Thrown = thrown; - Target = target; - } - } -} diff --git a/Content.Shared/Throwing/ThrowEvents.cs b/Content.Shared/Throwing/ThrowEvents.cs new file mode 100644 index 0000000000..714ff3af7b --- /dev/null +++ b/Content.Shared/Throwing/ThrowEvents.cs @@ -0,0 +1,55 @@ +using System; +using JetBrains.Annotations; +using Robust.Shared.Analyzers; +using Robust.Shared.GameObjects; + +namespace Content.Shared.Throwing +{ + /// + /// Base class for all throw events. + /// + public abstract class ThrowEvent : HandledEntityEventArgs + { + /// + /// The entity that threw . + /// + public IEntity? User { get; } + + /// + /// The entity thrown by that hit + /// + public IEntity Thrown { get; } + + /// + /// The entity hit with by + /// + public IEntity Target { get; } + + public ThrowEvent(IEntity? user, IEntity thrown, IEntity target) + { + User = user; + Thrown = thrown; + Target = target; + } + } + + /// + /// Raised directed on the target entity being hit by the thrown entity. + /// + public class ThrowHitByEvent : ThrowEvent + { + public ThrowHitByEvent(IEntity? user, IEntity thrown, IEntity target) : base(user, thrown, target) + { + } + } + + /// + /// Raised directed on the thrown entity that hits another. + /// + public class ThrowDoHitEvent : ThrowEvent + { + public ThrowDoHitEvent(IEntity? user, IEntity thrown, IEntity target) : base(user, thrown, target) + { + } + } +} diff --git a/Content.Shared/Throwing/ThrownItemSystem.cs b/Content.Shared/Throwing/ThrownItemSystem.cs index a258492600..7174709102 100644 --- a/Content.Shared/Throwing/ThrownItemSystem.cs +++ b/Content.Shared/Throwing/ThrownItemSystem.cs @@ -14,8 +14,6 @@ namespace Content.Shared.Throwing /// public class ThrownItemSystem : EntitySystem { - private List _throwCollide = new(); - private const string ThrowingFixture = "throw-fixture"; public override void Initialize() @@ -117,46 +115,13 @@ namespace Content.Shared.Throwing } /// - /// Calls ThrowCollide on all components that implement the IThrowCollide interface - /// on a thrown entity and the target entity it hit. + /// Raises collision events on the thrown and target entities. /// public void ThrowCollideInteraction(IEntity? user, IPhysBody thrown, IPhysBody target) { // TODO: Just pass in the bodies directly - var collideMsg = new ThrowCollideEvent(user, thrown.Owner, target.Owner); - RaiseLocalEvent(target.Owner.Uid, collideMsg); - if (collideMsg.Handled) - { - return; - } - - var eventArgs = new ThrowCollideEventArgs(user, thrown.Owner, target.Owner); - - foreach (var comp in target.Owner.GetAllComponents()) - { - _throwCollide.Add(comp); - } - - foreach (var collide in _throwCollide) - { - if (target.Owner.Deleted) break; - collide.HitBy(eventArgs); - } - - _throwCollide.Clear(); - - foreach (var comp in thrown.Owner.GetAllComponents()) - { - _throwCollide.Add(comp); - } - - foreach (var collide in _throwCollide) - { - if (thrown.Owner.Deleted) break; - collide.DoHit(eventArgs); - } - - _throwCollide.Clear(); + RaiseLocalEvent(target.Owner.Uid, new ThrowHitByEvent(user, thrown.Owner, target.Owner)); + RaiseLocalEvent(thrown.Owner.Uid, new ThrowDoHitEvent(user, thrown.Owner, target.Owner)); } } } diff --git a/Resources/Prototypes/Entities/Objects/Weapons/Guns/Projectiles/projectiles.yml b/Resources/Prototypes/Entities/Objects/Weapons/Guns/Projectiles/projectiles.yml index 43efb5308c..816843660e 100644 --- a/Resources/Prototypes/Entities/Objects/Weapons/Guns/Projectiles/projectiles.yml +++ b/Resources/Prototypes/Entities/Objects/Weapons/Guns/Projectiles/projectiles.yml @@ -299,16 +299,18 @@ description: get creampied, honk!! abstract: true components: - - type: Projectile - deleteOnCollide: false # CreamPie component handles this. - - type: CreamPie - - type: ThrownItem - - type: Sprite - netsync: false - sprite: Objects/Consumable/Food/pie.rsi - state: icon - - type: SolutionContainer - contents: - reagents: - - ReagentId: Nutriment - Quantity: 8 + - type: Projectile + deleteOnCollide: false # CreamPie component handles this. + - type: CreamPie + - type: ThrownItem + - type: Sprite + sprite: Objects/Consumable/Food/Baked/pie.rsi + netsync: false + layers: + - state: tin + - state: plain + - type: SolutionContainer + contents: + reagents: + - ReagentId: Nutriment + Quantity: 8