Evac shuttle (#8931)
Co-authored-by: metalgearsloth <metalgearsloth@gmail.com>
This commit is contained in:
@@ -0,0 +1,7 @@
|
||||
namespace Content.Server.Shuttles.Components;
|
||||
|
||||
/// <summary>
|
||||
/// Given priority when considering where to dock an emergency shuttle.
|
||||
/// </summary>
|
||||
[RegisterComponent]
|
||||
public sealed class EmergencyDockComponent : Component {}
|
||||
@@ -0,0 +1,16 @@
|
||||
namespace Content.Server.Shuttles.Components;
|
||||
|
||||
[RegisterComponent]
|
||||
public sealed class EmergencyShuttleConsoleComponent : Component
|
||||
{
|
||||
// TODO: Okay doing it by string is kinda suss but also ID card tracking doesn't seem to be robust enough
|
||||
|
||||
/// <summary>
|
||||
/// ID cards that have been used to authorize an early launch.
|
||||
/// </summary>
|
||||
[ViewVariables(VVAccess.ReadWrite), DataField("authorized")]
|
||||
public HashSet<string> AuthorizedEntities = new();
|
||||
|
||||
[ViewVariables(VVAccess.ReadWrite), DataField("authorizationsRequired")]
|
||||
public int AuthorizationsRequired = 3;
|
||||
}
|
||||
31
Content.Server/Shuttles/Components/HyperspaceComponent.cs
Normal file
31
Content.Server/Shuttles/Components/HyperspaceComponent.cs
Normal file
@@ -0,0 +1,31 @@
|
||||
using Robust.Shared.Map;
|
||||
|
||||
namespace Content.Server.Shuttles.Components;
|
||||
|
||||
/// <summary>
|
||||
/// Added to a component when it is queued or is travelling through hyperspace
|
||||
/// </summary>
|
||||
[RegisterComponent]
|
||||
public sealed class HyperspaceComponent : Component
|
||||
{
|
||||
[ViewVariables]
|
||||
public HyperspaceState State = HyperspaceState.Starting;
|
||||
|
||||
[ViewVariables(VVAccess.ReadWrite)]
|
||||
public float StartupTime = 0f;
|
||||
|
||||
[ViewVariables(VVAccess.ReadWrite)]
|
||||
public float TravelTime = 0f;
|
||||
|
||||
[ViewVariables(VVAccess.ReadWrite)]
|
||||
public float Accumulator = 0f;
|
||||
|
||||
[ViewVariables(VVAccess.ReadWrite), DataField("targetCoordinates")]
|
||||
public EntityCoordinates TargetCoordinates;
|
||||
}
|
||||
|
||||
public enum HyperspaceState : byte
|
||||
{
|
||||
Starting,
|
||||
Travelling,
|
||||
}
|
||||
@@ -5,6 +5,12 @@ namespace Content.Server.Shuttles.Components
|
||||
[RegisterComponent]
|
||||
public sealed class ShuttleComponent : Component
|
||||
{
|
||||
/// <summary>
|
||||
/// Should controls be enabled or disabled on this shuttle.
|
||||
/// </summary>
|
||||
[ViewVariables(VVAccess.ReadWrite)]
|
||||
public bool CanPilot = true;
|
||||
|
||||
[ViewVariables]
|
||||
public bool Enabled = true;
|
||||
|
||||
|
||||
@@ -5,6 +5,12 @@ namespace Content.Server.Shuttles.Components
|
||||
[RegisterComponent]
|
||||
public sealed class ShuttleConsoleComponent : SharedShuttleConsoleComponent
|
||||
{
|
||||
/// <summary>
|
||||
/// Set by shuttlesystem if the grid should no longer be pilotable.
|
||||
/// </summary>
|
||||
[ViewVariables]
|
||||
public bool CanPilot = true;
|
||||
|
||||
[ViewVariables]
|
||||
public readonly List<PilotComponent> SubscribedPilots = new();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user