ModifyWearerNameComponent.cs 816 B

12345678910111213141516171819202122232425
  1. using Robust.Shared.GameStates;
  2. namespace Content.Shared.NameModifier.Components;
  3. /// <summary>
  4. /// Adds a modifier to the wearer's name when this item is equipped,
  5. /// and removes it when it is unequipped.
  6. /// </summary>
  7. [RegisterComponent, NetworkedComponent]
  8. [AutoGenerateComponentState]
  9. public sealed partial class ModifyWearerNameComponent : Component
  10. {
  11. /// <summary>
  12. /// The localization ID of the text to be used as the modifier.
  13. /// The base name will be passed in as <c>$baseName</c>
  14. /// </summary>
  15. [DataField, AutoNetworkedField]
  16. public LocId LocId = string.Empty;
  17. /// <summary>
  18. /// Priority of the modifier. See <see cref="EntitySystems.RefreshNameModifiersEvent"/> for more information.
  19. /// </summary>
  20. [DataField, AutoNetworkedField]
  21. public int Priority;
  22. }