* Station AI overlay * implement * Bunch of ports * Fix a heap of bugs and basic scouting * helldivers * Shuffle interactions a bit * navmap stuff * Revert "navmap stuff" This reverts commit d1f89dd4be83233e22cf5dd062b2581f3c6da062. * AI wires implemented * Fix examines * Optimise the overlay significantly * Back to old static * BUI radial working * lots of work * Saving work * thanks fork * alright * pc * AI upload console * AI upload * stuff * Fix copy-paste shitcode * AI actions * navmap work * Fixes * first impressions * a * reh * Revert "navmap work" This reverts commit 6f63fea6e9245e189f368f97be3e32e9b210580e. # Conflicts: # Content.Client/Silicons/StationAi/StationAiOverlay.cs * OD * radar * weh * Fix examines * scoop mine eyes * fixes * reh * Optimise * Final round of optimisations * Fixes * fixes
62 lines
1.5 KiB
C#
62 lines
1.5 KiB
C#
using Content.Shared.Actions;
|
|
using Robust.Shared.GameStates;
|
|
using Robust.Shared.Prototypes;
|
|
using Robust.Shared.Serialization;
|
|
|
|
namespace Content.Shared.Silicons.Laws.Components;
|
|
|
|
/// <summary>
|
|
/// This is used for entities which are bound to silicon laws and can view them.
|
|
/// </summary>
|
|
[RegisterComponent, NetworkedComponent, Access(typeof(SharedSiliconLawSystem))]
|
|
public sealed partial class SiliconLawBoundComponent : Component
|
|
{
|
|
/// <summary>
|
|
/// The last entity that provided laws to this entity.
|
|
/// </summary>
|
|
[DataField]
|
|
public EntityUid? LastLawProvider;
|
|
}
|
|
|
|
/// <summary>
|
|
/// Event raised to get the laws that a law-bound entity has.
|
|
///
|
|
/// Is first raised on the entity itself, then on the
|
|
/// entity's station, then on the entity's grid,
|
|
/// before being broadcast.
|
|
/// </summary>
|
|
/// <param name="Entity"></param>
|
|
[ByRefEvent]
|
|
public record struct GetSiliconLawsEvent(EntityUid Entity)
|
|
{
|
|
public EntityUid Entity = Entity;
|
|
|
|
public SiliconLawset Laws = new();
|
|
|
|
public bool Handled = false;
|
|
}
|
|
|
|
public sealed partial class ToggleLawsScreenEvent : InstantActionEvent
|
|
{
|
|
|
|
}
|
|
|
|
[NetSerializable, Serializable]
|
|
public enum SiliconLawsUiKey : byte
|
|
{
|
|
Key
|
|
}
|
|
|
|
[Serializable, NetSerializable]
|
|
public sealed class SiliconLawBuiState : BoundUserInterfaceState
|
|
{
|
|
public List<SiliconLaw> Laws;
|
|
public HashSet<string>? RadioChannels;
|
|
|
|
public SiliconLawBuiState(List<SiliconLaw> laws, HashSet<string>? radioChannels)
|
|
{
|
|
Laws = laws;
|
|
RadioChannels = radioChannels;
|
|
}
|
|
}
|