1
0

SpillableComponent.cs 915 B

12345678910111213141516171819202122232425262728293031
  1. using Content.Shared.FixedPoint;
  2. namespace Content.Shared.Fluids.Components;
  3. /// <summary>
  4. /// Makes a solution contained in this entity spillable.
  5. /// Spills can occur when a container with this component overflows,
  6. /// is used to melee attack something, is equipped (see <see cref="SpillWorn"/>),
  7. /// lands after being thrown, or has the Spill verb used.
  8. /// </summary>
  9. [RegisterComponent]
  10. public sealed partial class SpillableComponent : Component
  11. {
  12. [DataField("solution")]
  13. public string SolutionName = "puddle";
  14. [DataField]
  15. public float? SpillDelay;
  16. /// <summary>
  17. /// At most how much reagent can be splashed on someone at once?
  18. /// </summary>
  19. [DataField]
  20. public FixedPoint2 MaxMeleeSpillAmount = FixedPoint2.New(20);
  21. /// <summary>
  22. /// Should this item be spilled when thrown?
  23. /// </summary>
  24. [DataField]
  25. public bool SpillWhenThrown = true;
  26. }