This commit is contained in:
Pieter-Jan Briers
2018-08-31 08:52:48 +02:00
committed by GitHub
parent bb5a278fdb
commit d414ea55f5
10 changed files with 632 additions and 59 deletions

View File

@@ -1,8 +1,15 @@
using System;
using SS14.Shared.GameObjects;
using SS14.Shared.GameObjects.Components.UserInterface;
using SS14.Shared.Serialization;
namespace Content.Shared.GameObjects.Components.Power
{
public abstract class SharedApcComponent : Component
{
public sealed override string Name => "Apc";
}
[Serializable, NetSerializable]
public enum ApcVisuals
{
@@ -27,4 +34,37 @@ namespace Content.Shared.GameObjects.Components.Power
/// </summary>
Full,
}
[Serializable, NetSerializable]
public sealed class ApcBoundInterfaceState : BoundUserInterfaceState
{
public readonly bool MainBreaker;
public readonly ApcExternalPowerState ApcExternalPower;
public readonly float Charge;
public ApcBoundInterfaceState(bool mainBreaker, ApcExternalPowerState apcExternalPower, float charge)
{
MainBreaker = mainBreaker;
ApcExternalPower = apcExternalPower;
Charge = charge;
}
}
[Serializable, NetSerializable]
public sealed class ApcToggleMainBreakerMessage : BoundUserInterfaceMessage
{
}
public enum ApcExternalPowerState
{
None,
Low,
Good,
}
[NetSerializable, Serializable]
public enum ApcUiKey
{
Key,
}
}