Seal/abstract/virtual everything (#6739)
This commit is contained in:
@@ -3,7 +3,7 @@ using Robust.Shared.GameObjects;
|
||||
namespace Content.Server.MachineLinking.Components
|
||||
{
|
||||
[RegisterComponent]
|
||||
public class SignalButtonComponent : Component
|
||||
public sealed class SignalButtonComponent : Component
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4,7 +4,7 @@ using Robust.Shared.ViewVariables;
|
||||
namespace Content.Server.MachineLinking.Components
|
||||
{
|
||||
[RegisterComponent]
|
||||
public class SignalLinkerComponent : Component
|
||||
public sealed class SignalLinkerComponent : Component
|
||||
{
|
||||
[ViewVariables]
|
||||
public (SignalTransmitterComponent transmitter, string port)? Port;
|
||||
|
||||
@@ -8,7 +8,7 @@ using Robust.Shared.ViewVariables;
|
||||
namespace Content.Server.MachineLinking.Components
|
||||
{
|
||||
[RegisterComponent]
|
||||
public class SignalReceiverComponent : Component
|
||||
public sealed class SignalReceiverComponent : Component
|
||||
{
|
||||
[DataField("inputs")]
|
||||
private List<SignalPort> _inputs = new();
|
||||
|
||||
@@ -3,7 +3,7 @@ using Robust.Shared.GameObjects;
|
||||
namespace Content.Server.MachineLinking.Components
|
||||
{
|
||||
[RegisterComponent]
|
||||
public class SignalSwitchComponent : Component
|
||||
public sealed class SignalSwitchComponent : Component
|
||||
{
|
||||
public bool State;
|
||||
}
|
||||
|
||||
@@ -8,7 +8,7 @@ using Robust.Shared.ViewVariables;
|
||||
namespace Content.Server.MachineLinking.Components
|
||||
{
|
||||
[RegisterComponent]
|
||||
public class SignalTransmitterComponent : Component
|
||||
public sealed class SignalTransmitterComponent : Component
|
||||
{
|
||||
[DataField("outputs")]
|
||||
private List<SignalPort> _outputs = new();
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
namespace Content.Server.MachineLinking.Components
|
||||
{
|
||||
[RegisterComponent]
|
||||
public class TriggerOnSignalReceivedComponent : Component
|
||||
public sealed class TriggerOnSignalReceivedComponent : Component
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4,7 +4,7 @@ using Robust.Shared.GameObjects;
|
||||
namespace Content.Server.MachineLinking.Components
|
||||
{
|
||||
[RegisterComponent]
|
||||
public class TwoWayLeverComponent : Component
|
||||
public sealed class TwoWayLeverComponent : Component
|
||||
{
|
||||
public TwoWayLeverSignal State;
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@ using Robust.Shared.GameObjects;
|
||||
|
||||
namespace Content.Server.MachineLinking.Events
|
||||
{
|
||||
public class InvokePortEvent : EntityEventArgs
|
||||
public sealed class InvokePortEvent : EntityEventArgs
|
||||
{
|
||||
public readonly string Port;
|
||||
public readonly object? Value;
|
||||
|
||||
@@ -3,7 +3,7 @@ using Robust.Shared.GameObjects;
|
||||
|
||||
namespace Content.Server.MachineLinking.Events
|
||||
{
|
||||
public class LinkAttemptEvent : CancellableEntityEventArgs
|
||||
public sealed class LinkAttemptEvent : CancellableEntityEventArgs
|
||||
{
|
||||
public readonly EntityUid Attemptee;
|
||||
public readonly SignalTransmitterComponent TransmitterComponent;
|
||||
|
||||
@@ -2,7 +2,7 @@ using Robust.Shared.GameObjects;
|
||||
|
||||
namespace Content.Server.MachineLinking.Events
|
||||
{
|
||||
public class PortDisconnectedEvent : EntityEventArgs
|
||||
public sealed class PortDisconnectedEvent : EntityEventArgs
|
||||
{
|
||||
public readonly string Port;
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@ using Robust.Shared.GameObjects;
|
||||
|
||||
namespace Content.Server.MachineLinking.Events
|
||||
{
|
||||
public class SignalReceivedEvent : EntityEventArgs
|
||||
public sealed class SignalReceivedEvent : EntityEventArgs
|
||||
{
|
||||
public readonly string Port;
|
||||
public readonly object? Value;
|
||||
|
||||
@@ -3,7 +3,7 @@ using Robust.Shared.GameObjects;
|
||||
|
||||
namespace Content.Server.MachineLinking.Events
|
||||
{
|
||||
public class SignalValueRequestedEvent : HandledEntityEventArgs
|
||||
public sealed class SignalValueRequestedEvent : HandledEntityEventArgs
|
||||
{
|
||||
public readonly string Port;
|
||||
public readonly Type Type;
|
||||
|
||||
@@ -2,7 +2,7 @@ using System;
|
||||
|
||||
namespace Content.Server.MachineLinking.Exceptions
|
||||
{
|
||||
public class InvalidPortValueException : Exception
|
||||
public sealed class InvalidPortValueException : Exception
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
namespace Content.Server.MachineLinking.Exceptions
|
||||
{
|
||||
public class LinkAlreadyRegisteredException : Exception
|
||||
public sealed class LinkAlreadyRegisteredException : Exception
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@ using System;
|
||||
|
||||
namespace Content.Server.MachineLinking.Exceptions
|
||||
{
|
||||
public class NoSignalValueProvidedException : Exception
|
||||
public sealed class NoSignalValueProvidedException : Exception
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@ using System;
|
||||
|
||||
namespace Content.Server.MachineLinking.Exceptions
|
||||
{
|
||||
public class PortNotFoundException : Exception
|
||||
public sealed class PortNotFoundException : Exception
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
namespace Content.Server.MachineLinking.Models
|
||||
{
|
||||
public class SignalLink
|
||||
public sealed class SignalLink
|
||||
{
|
||||
public readonly SignalTransmitterComponent TransmitterComponent;
|
||||
public readonly SignalReceiverComponent ReceiverComponent;
|
||||
|
||||
@@ -4,7 +4,7 @@ using Content.Server.MachineLinking.Exceptions;
|
||||
|
||||
namespace Content.Server.MachineLinking.Models
|
||||
{
|
||||
public class SignalLinkCollection
|
||||
public sealed class SignalLinkCollection
|
||||
{
|
||||
private Dictionary<SignalTransmitterComponent, List<SignalLink>> _transmitterDict = new();
|
||||
private Dictionary<SignalReceiverComponent, List<SignalLink>> _receiverDict = new();
|
||||
|
||||
@@ -8,7 +8,7 @@ using Robust.Shared.Serialization.Manager.Attributes;
|
||||
namespace Content.Server.MachineLinking.Models
|
||||
{
|
||||
[DataDefinition]
|
||||
public class SignalPort
|
||||
public sealed class SignalPort
|
||||
{
|
||||
[DataField("name", required: true)] public string Name { get; } = default!;
|
||||
[DataField("type")] public Type? Type { get; }
|
||||
|
||||
@@ -7,7 +7,7 @@ using Robust.Shared.GameObjects;
|
||||
namespace Content.Server.MachineLinking.System
|
||||
{
|
||||
[UsedImplicitly]
|
||||
public class SignalButtonSystem : EntitySystem
|
||||
public sealed class SignalButtonSystem : EntitySystem
|
||||
{
|
||||
public override void Initialize()
|
||||
{
|
||||
|
||||
@@ -18,7 +18,7 @@ using Robust.Shared.Utility;
|
||||
|
||||
namespace Content.Server.MachineLinking.System
|
||||
{
|
||||
public class SignalLinkerSystem : EntitySystem
|
||||
public sealed class SignalLinkerSystem : EntitySystem
|
||||
{
|
||||
private InteractionSystem _interaction = default!;
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ using Robust.Shared.GameObjects;
|
||||
|
||||
namespace Content.Server.MachineLinking.System
|
||||
{
|
||||
public class SignalSwitchSystem : EntitySystem
|
||||
public sealed class SignalSwitchSystem : EntitySystem
|
||||
{
|
||||
public override void Initialize()
|
||||
{
|
||||
|
||||
@@ -6,7 +6,7 @@ using Robust.Shared.IoC;
|
||||
|
||||
namespace Content.Server.MachineLinking.System
|
||||
{
|
||||
public class TriggerOnSignalReceivedSystem : EntitySystem
|
||||
public sealed class TriggerOnSignalReceivedSystem : EntitySystem
|
||||
{
|
||||
[Dependency] private readonly TriggerSystem _trigger = default!;
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ using Robust.Shared.IoC;
|
||||
|
||||
namespace Content.Server.MachineLinking.System
|
||||
{
|
||||
public class TwoWayLeverSystem : EntitySystem
|
||||
public sealed class TwoWayLeverSystem : EntitySystem
|
||||
{
|
||||
public override void Initialize()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user