Hunger and thirst HUDs (#18066)
* security HUD now shows a job icon on entities with a body * thirst goggles * set starting hud gear
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
using Robust.Shared.Prototypes;
|
||||
using Robust.Shared.Prototypes;
|
||||
using Robust.Shared.Serialization;
|
||||
using Robust.Shared.Utility;
|
||||
|
||||
namespace Content.Shared.StatusIcon;
|
||||
@@ -22,6 +23,12 @@ public class StatusIconData : IComparable<StatusIconData>
|
||||
[DataField("priority")]
|
||||
public int Priority = 10;
|
||||
|
||||
/// <summary>
|
||||
/// A preference for where the icon will be displayed. None | Left | Right
|
||||
/// </summary>
|
||||
[DataField("locationPreference")]
|
||||
public StatusIconLocationPreference LocationPreference = StatusIconLocationPreference.None;
|
||||
|
||||
public int CompareTo(StatusIconData? other)
|
||||
{
|
||||
return Priority.CompareTo(other?.Priority ?? int.MaxValue);
|
||||
@@ -38,3 +45,11 @@ public sealed class StatusIconPrototype : StatusIconData, IPrototype
|
||||
[IdDataField]
|
||||
public string ID { get; } = default!;
|
||||
}
|
||||
|
||||
[Serializable, NetSerializable]
|
||||
public enum StatusIconLocationPreference : byte
|
||||
{
|
||||
None,
|
||||
Left,
|
||||
Right,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user