Vending visualizer update (#9962)

This commit is contained in:
Leon Friedrich
2022-07-26 12:35:36 +12:00
committed by GitHub
parent a21bcb4363
commit 5449e7875e
9 changed files with 113 additions and 78 deletions

View File

@@ -1,13 +1,18 @@
using Content.Shared.Actions;
using Robust.Shared.GameStates;
using Robust.Shared.Serialization;
using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom.Prototype;
namespace Content.Shared.VendingMachines
{
[Virtual]
[NetworkedComponent()]
public class SharedVendingMachineComponent : Component
public abstract class SharedVendingMachineComponent : Component
{
[DataField("pack", customTypeSerializer: typeof(PrototypeIdSerializer<VendingMachineInventoryPrototype>))]
public string PackPrototypeId = string.Empty;
public TimeSpan AnimationDuration = TimeSpan.Zero;
[ViewVariables] public List<VendingMachineInventoryEntry> Inventory = new();
[ViewVariables] public List<VendingMachineInventoryEntry> EmaggedInventory = new();
[ViewVariables] public List<VendingMachineInventoryEntry> ContrabandInventory = new();
@@ -32,6 +37,7 @@ namespace Content.Shared.VendingMachines
public enum VendingMachineVisuals
{
VisualState,
Inventory,
}
[Serializable, NetSerializable]