Scurret naming fixes (#38776)

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>
This commit is contained in:
Hannah Giovanna Dawson
2025-07-06 23:30:44 +01:00
committed by GitHub
parent 575694e5b5
commit f5fd2dcb76
6 changed files with 112 additions and 30 deletions

View File

@@ -1,5 +1,5 @@
using Robust.Shared.GameStates;
using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom.Prototype;
using Robust.Shared.Prototypes;
namespace Content.Shared.NameIdentifier;
@@ -9,18 +9,18 @@ namespace Content.Shared.NameIdentifier;
[RegisterComponent, NetworkedComponent, AutoGenerateComponentState]
public sealed partial class NameIdentifierComponent : Component
{
[DataField("group", required: true, customTypeSerializer:typeof(PrototypeIdSerializer<NameIdentifierGroupPrototype>))]
public string Group = string.Empty;
[DataField]
public ProtoId<NameIdentifierGroupPrototype>? Group;
/// <summary>
/// The randomly generated ID for this entity.
/// </summary>
[DataField("identifier"), ViewVariables(VVAccess.ReadWrite), AutoNetworkedField]
[DataField, AutoNetworkedField]
public int Identifier = -1;
/// <summary>
/// The full name identifier for this entity.
/// </summary>
[DataField("fullIdentifier"), ViewVariables(VVAccess.ReadWrite), AutoNetworkedField]
[DataField, AutoNetworkedField]
public string FullIdentifier = string.Empty;
}