Update trivial components to use auto comp states (#20539)
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
using Content.Shared.Access.Systems;
|
||||
using Content.Shared.Containers.ItemSlots;
|
||||
using Robust.Shared.GameStates;
|
||||
using Robust.Shared.Prototypes;
|
||||
using Robust.Shared.Serialization;
|
||||
using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom.Prototype.List;
|
||||
|
||||
namespace Content.Shared.Access.Components;
|
||||
|
||||
[RegisterComponent, NetworkedComponent]
|
||||
[RegisterComponent, NetworkedComponent, AutoGenerateComponentState]
|
||||
[Access(typeof(SharedIdCardConsoleSystem))]
|
||||
public sealed partial class IdCardConsoleComponent : Component
|
||||
{
|
||||
@@ -16,10 +16,10 @@ public sealed partial class IdCardConsoleComponent : Component
|
||||
public static string PrivilegedIdCardSlotId = "IdCardConsole-privilegedId";
|
||||
public static string TargetIdCardSlotId = "IdCardConsole-targetId";
|
||||
|
||||
[DataField("privilegedIdSlot")]
|
||||
[DataField]
|
||||
public ItemSlot PrivilegedIdSlot = new();
|
||||
|
||||
[DataField("targetIdSlot")]
|
||||
[DataField]
|
||||
public ItemSlot TargetIdSlot = new();
|
||||
|
||||
[Serializable, NetSerializable]
|
||||
@@ -41,8 +41,8 @@ public sealed partial class IdCardConsoleComponent : Component
|
||||
|
||||
// Put this on shared so we just send the state once in PVS range rather than every time the UI updates.
|
||||
|
||||
[DataField("accessLevels", customTypeSerializer: typeof(PrototypeIdListSerializer<AccessLevelPrototype>))]
|
||||
public List<string> AccessLevels = new()
|
||||
[DataField, AutoNetworkedField]
|
||||
public List<ProtoId<AccessLevelPrototype>> AccessLevels = new()
|
||||
{
|
||||
"Armory",
|
||||
"Atmospherics",
|
||||
|
||||
Reference in New Issue
Block a user