* lathe and material storage refactor * materialStorage ECS it kinda sus tho * beginning the lathe shitcode dive * couple lathe visuals and lathe system * lathe changes and such * dynamic lathe databases * rewrote internal logic on to ui * da newI * material display clientside * misc ui changes * component state handling and various other things * moar * Update Content.Shared/Lathe/LatheComponent.cs Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com> * first volley of sloth review * more fixes * losin' my mind * all da changes * test fix and other review Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
61 lines
1.6 KiB
C#
61 lines
1.6 KiB
C#
using Content.Shared.Research.Prototypes;
|
|
using Robust.Shared.Serialization;
|
|
|
|
namespace Content.Shared.Lathe;
|
|
|
|
[Serializable, NetSerializable]
|
|
public sealed class LatheUpdateState : BoundUserInterfaceState
|
|
{
|
|
public List<string> Recipes;
|
|
|
|
public List<LatheRecipePrototype> Queue;
|
|
|
|
public LatheRecipePrototype? CurrentlyProducing;
|
|
|
|
public LatheUpdateState(List<string> recipes, List<LatheRecipePrototype> queue, LatheRecipePrototype? currentlyProducing = null)
|
|
{
|
|
Recipes = recipes;
|
|
Queue = queue;
|
|
CurrentlyProducing = currentlyProducing;
|
|
}
|
|
}
|
|
|
|
/// <summary>
|
|
/// Sent to the server to sync material storage and the recipe queue.
|
|
/// </summary>
|
|
[Serializable, NetSerializable]
|
|
public sealed class LatheSyncRequestMessage : BoundUserInterfaceMessage { }
|
|
|
|
/// <summary>
|
|
/// Sent to the server to sync the lathe's technology database with the research server.
|
|
/// </summary>
|
|
[Serializable, NetSerializable]
|
|
public sealed class LatheServerSyncMessage : BoundUserInterfaceMessage { }
|
|
|
|
/// <summary>
|
|
/// Sent to the server to open the ResearchClient UI.
|
|
/// </summary>
|
|
[Serializable, NetSerializable]
|
|
public sealed class LatheServerSelectionMessage : BoundUserInterfaceMessage { }
|
|
|
|
/// <summary>
|
|
/// Sent to the server when a client queues a new recipe.
|
|
/// </summary>
|
|
[Serializable, NetSerializable]
|
|
public sealed class LatheQueueRecipeMessage : BoundUserInterfaceMessage
|
|
{
|
|
public readonly string ID;
|
|
public readonly int Quantity;
|
|
public LatheQueueRecipeMessage(string id, int quantity)
|
|
{
|
|
ID = id;
|
|
Quantity = quantity;
|
|
}
|
|
}
|
|
|
|
[NetSerializable, Serializable]
|
|
public enum LatheUiKey
|
|
{
|
|
Key,
|
|
}
|