Files
tbd-station-14/Content.Shared/Fluids/Components/SpillWhenWornComponent.cs
Tayrtahn 880fef507d Replace BlockSolutionAccessComponent with an attempt event (#26988)
* BlockSolutionAccessComponent now only blocks one specified solution.

* Significant overhaul
Separated spilling when worn functionality into its own component/system.
Removed BlockSolutionAccessComponent.
Added an event for solution access.
2024-06-21 13:04:02 +10:00

25 lines
671 B
C#

using Robust.Shared.GameStates;
namespace Content.Shared.Fluids.Components;
/// <summary>
/// This entity will spill its contained solution onto the wearer when worn, and its
/// (empty) contents will be inaccessible while still worn.
/// </summary>
[RegisterComponent]
[NetworkedComponent, AutoGenerateComponentState]
public sealed partial class SpillWhenWornComponent : Component
{
/// <summary>
/// Name of the solution to spill.
/// </summary>
[DataField]
public string Solution = "default";
/// <summary>
/// Tracks if this item is currently being worn.
/// </summary>
[DataField, AutoNetworkedField]
public bool IsWorn;
}