Seal/abstract/virtual everything (#6739)
This commit is contained in:
@@ -10,6 +10,7 @@ using Robust.Shared.Serialization;
|
||||
namespace Content.Shared.Lathe
|
||||
{
|
||||
[NetworkedComponent()]
|
||||
[Virtual]
|
||||
public class SharedLatheComponent : Component
|
||||
{
|
||||
[Dependency] private readonly IEntityManager _entMan = default!;
|
||||
@@ -38,7 +39,7 @@ namespace Content.Shared.Lathe
|
||||
/// Sent to the server to sync material storage and the recipe queue.
|
||||
/// </summary>
|
||||
[Serializable, NetSerializable]
|
||||
public class LatheSyncRequestMessage : BoundUserInterfaceMessage
|
||||
public sealed class LatheSyncRequestMessage : BoundUserInterfaceMessage
|
||||
{
|
||||
public LatheSyncRequestMessage()
|
||||
{
|
||||
@@ -51,7 +52,7 @@ namespace Content.Shared.Lathe
|
||||
/// Sent to the server to sync the lathe's technology database with the research server.
|
||||
/// </summary>
|
||||
[Serializable, NetSerializable]
|
||||
public class LatheServerSyncMessage : BoundUserInterfaceMessage
|
||||
public sealed class LatheServerSyncMessage : BoundUserInterfaceMessage
|
||||
{
|
||||
public LatheServerSyncMessage()
|
||||
{
|
||||
@@ -62,7 +63,7 @@ namespace Content.Shared.Lathe
|
||||
/// Sent to the server to open the ResearchClient UI.
|
||||
/// </summary>
|
||||
[Serializable, NetSerializable]
|
||||
public class LatheServerSelectionMessage : BoundUserInterfaceMessage
|
||||
public sealed class LatheServerSelectionMessage : BoundUserInterfaceMessage
|
||||
{
|
||||
public LatheServerSelectionMessage()
|
||||
{
|
||||
@@ -73,7 +74,7 @@ namespace Content.Shared.Lathe
|
||||
/// Sent to the client when the lathe is producing a recipe.
|
||||
/// </summary>
|
||||
[Serializable, NetSerializable]
|
||||
public class LatheProducingRecipeMessage : BoundUserInterfaceMessage
|
||||
public sealed class LatheProducingRecipeMessage : BoundUserInterfaceMessage
|
||||
{
|
||||
public readonly string ID;
|
||||
public LatheProducingRecipeMessage(string id)
|
||||
@@ -86,7 +87,7 @@ namespace Content.Shared.Lathe
|
||||
/// Sent to the client when the lathe stopped/finished producing a recipe.
|
||||
/// </summary>
|
||||
[Serializable, NetSerializable]
|
||||
public class LatheStoppedProducingRecipeMessage : BoundUserInterfaceMessage
|
||||
public sealed class LatheStoppedProducingRecipeMessage : BoundUserInterfaceMessage
|
||||
{
|
||||
public LatheStoppedProducingRecipeMessage()
|
||||
{
|
||||
@@ -97,7 +98,7 @@ namespace Content.Shared.Lathe
|
||||
/// Sent to the client to let it know about the recipe queue.
|
||||
/// </summary>
|
||||
[Serializable, NetSerializable]
|
||||
public class LatheFullQueueMessage : BoundUserInterfaceMessage
|
||||
public sealed class LatheFullQueueMessage : BoundUserInterfaceMessage
|
||||
{
|
||||
public readonly Queue<string> Recipes;
|
||||
public LatheFullQueueMessage(Queue<string> recipes)
|
||||
@@ -110,7 +111,7 @@ namespace Content.Shared.Lathe
|
||||
/// Sent to the server when a client queues a new recipe.
|
||||
/// </summary>
|
||||
[Serializable, NetSerializable]
|
||||
public class LatheQueueRecipeMessage : BoundUserInterfaceMessage
|
||||
public sealed class LatheQueueRecipeMessage : BoundUserInterfaceMessage
|
||||
{
|
||||
public readonly string ID;
|
||||
public readonly int Quantity;
|
||||
|
||||
@@ -13,7 +13,7 @@ using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom.Prototy
|
||||
namespace Content.Shared.Lathe
|
||||
{
|
||||
[NetworkedComponent()]
|
||||
public class SharedLatheDatabaseComponent : Component, IEnumerable<LatheRecipePrototype>, ISerializationHooks
|
||||
public abstract class SharedLatheDatabaseComponent : Component, IEnumerable<LatheRecipePrototype>, ISerializationHooks
|
||||
{
|
||||
[DataField("recipes", customTypeSerializer: typeof(PrototypeIdListSerializer<LatheRecipePrototype>))] private List<string> _recipeIds = new();
|
||||
|
||||
@@ -122,7 +122,7 @@ namespace Content.Shared.Lathe
|
||||
}
|
||||
|
||||
[NetSerializable, Serializable]
|
||||
public class LatheDatabaseState : ComponentState
|
||||
public sealed class LatheDatabaseState : ComponentState
|
||||
{
|
||||
public readonly List<string> Recipes;
|
||||
public LatheDatabaseState(List<string> recipes)
|
||||
|
||||
@@ -10,7 +10,7 @@ using Robust.Shared.ViewVariables;
|
||||
namespace Content.Shared.Lathe
|
||||
{
|
||||
[NetworkedComponent()]
|
||||
public class SharedMaterialStorageComponent : Component, IEnumerable<KeyValuePair<string, int>>
|
||||
public abstract class SharedMaterialStorageComponent : Component, IEnumerable<KeyValuePair<string, int>>
|
||||
{
|
||||
[ViewVariables]
|
||||
protected virtual Dictionary<string, int> Storage { get; set; } = new();
|
||||
@@ -66,7 +66,7 @@ namespace Content.Shared.Lathe
|
||||
}
|
||||
|
||||
[NetSerializable, Serializable]
|
||||
public class MaterialStorageState : ComponentState
|
||||
public sealed class MaterialStorageState : ComponentState
|
||||
{
|
||||
public readonly Dictionary<string, int> Storage;
|
||||
public MaterialStorageState(Dictionary<string, int> storage)
|
||||
|
||||
@@ -13,7 +13,7 @@ namespace Content.Shared.Lathe
|
||||
{
|
||||
[ComponentReference(typeof(SharedLatheDatabaseComponent))]
|
||||
[NetworkedComponent()]
|
||||
public class SharedProtolatheDatabaseComponent : SharedLatheDatabaseComponent, ISerializationHooks
|
||||
public abstract class SharedProtolatheDatabaseComponent : SharedLatheDatabaseComponent, ISerializationHooks
|
||||
{
|
||||
[Dependency] private readonly IPrototypeManager _prototypeManager = default!;
|
||||
|
||||
@@ -36,7 +36,7 @@ namespace Content.Shared.Lathe
|
||||
}
|
||||
|
||||
[NetSerializable, Serializable]
|
||||
public class ProtolatheDatabaseState : ComponentState
|
||||
public sealed class ProtolatheDatabaseState : ComponentState
|
||||
{
|
||||
public readonly List<string> Recipes;
|
||||
public ProtolatheDatabaseState(List<string> recipes)
|
||||
|
||||
Reference in New Issue
Block a user