Fix server crash for name identifiers (#15584)

This commit is contained in:
metalgearsloth
2023-05-02 02:56:44 +10:00
committed by GitHub
parent e2538b0185
commit ac5afa794e
3 changed files with 89 additions and 29 deletions

View File

@@ -8,4 +8,10 @@ public sealed class NameIdentifierComponent : Component
{
[DataField("group", required: true, customTypeSerializer:typeof(PrototypeIdSerializer<NameIdentifierGroupPrototype>))]
public string Group = string.Empty;
/// <summary>
/// The randomly generated ID for this entity.
/// </summary>
[ViewVariables(VVAccess.ReadWrite), DataField("identifier")]
public int Identifier = -1;
}