CatStation/Content.Shared/Nutrition/Components/CreamPiedComponent.cs
SlamBamActionman 24485c39ee
Change dwarves to use displacement maps instead of sprite scaling (#43816)
* ach, ye initial commit

* Review changes...?

* Change parentage

* Widen the dwarf sprite

* Widen the dwarf sprite

* Solve the murder at the Portermeister Estate

* The rest of the fucking owl

* Fix female displacement, fix the displacement error

* Review changes

* Review fixes

* IPrototypeManager to ProtoMan

* Review changes
2026-07-05 22:17:17 +00:00

56 lines
1.6 KiB
C#

using Content.Shared.DisplacementMap;
using Content.Shared.Nutrition.EntitySystems;
using Robust.Shared.GameStates;
using Robust.Shared.Prototypes;
using Robust.Shared.Serialization;
using Robust.Shared.Utility;
namespace Content.Shared.Nutrition.Components;
/// <summary>
/// Allows this entity to be hit by banana cream pies.
/// See <see cref="CreamPieComponent"/>.
/// </summary>
[Access(typeof(SharedCreamPieSystem))]
[RegisterComponent, NetworkedComponent, AutoGenerateComponentState(raiseAfterAutoHandleState: true)]
public sealed partial class CreamPiedComponent : Component
{
/// <summary>
/// Was this entity hit by a banana cream pie?
/// This is reset if they get splashed with water.
/// </summary>
[DataField, AutoNetworkedField]
public bool CreamPied;
/// <summary>
/// The sprite to draw on someone's face if they were hit by a pie.
/// The layer will be dynamically added with the component.
/// </summary>
[DataField, AutoNetworkedField]
public SpriteSpecifier? Sprite;
/// <summary>
/// If set, applies a displacement map to the pie sprite.
/// </summary>
[DataField, AutoNetworkedField]
public ProtoId<DisplacementDataPrototype>? Displacement;
}
/// <summary>
/// Key to be used with appearance data, indicating if the entity has a banana cream pie in their face.
/// </summary>
[Serializable, NetSerializable]
public enum CreamPiedVisuals
{
Creamed,
}
/// <summary>
/// The visual layer for the creampied face.
/// Will be dynamically added and removed with the component.
/// </summary>
[Serializable, NetSerializable]
public enum CreamPiedVisualLayer
{
Key,
}