Skip to content

Commit

Permalink
Init
Browse files Browse the repository at this point in the history
  • Loading branch information
ScarKy0 committed Sep 19, 2024
1 parent b32bdbf commit d927a6f
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 10 deletions.
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
using Content.Shared.CriminalRecords.Systems;
using Content.Shared.Radio;
using Content.Shared.StationRecords;
using Robust.Shared.GameStates;
using Robust.Shared.Prototypes;

namespace Content.Shared.CriminalRecords.Components;

/// <summary>
/// A component for Criminal Record Console storing an active station record key and a currently applied filter
/// </summary>
[RegisterComponent]
[RegisterComponent, NetworkedComponent, AutoGenerateComponentState]
[Access(typeof(SharedCriminalRecordsConsoleSystem))]
public sealed partial class CriminalRecordsConsoleComponent : Component
{
Expand All @@ -22,24 +23,24 @@ public sealed partial class CriminalRecordsConsoleComponent : Component
/// Server then sends a state with just the records, not the listing or filter, and the client updates just that.
/// I don't know if it's possible to have multiple bui states right now.
/// </remarks>
[DataField]
[DataField, AutoNetworkedField]
public uint? ActiveKey;

/// <summary>
/// Currently applied filter.
/// </summary>
[DataField]
[DataField, AutoNetworkedField]
public StationRecordsFilter? Filter;

/// <summary>
/// Channel to send messages to when someone's status gets changed.
/// </summary>
[DataField]
[DataField, AutoNetworkedField]
public ProtoId<RadioChannelPrototype> SecurityChannel = "Security";

/// <summary>
/// Max length of arrest and crime history strings.
/// </summary>
[DataField]
[DataField, AutoNetworkedField]
public uint MaxStringLength = 256;
}
13 changes: 13 additions & 0 deletions Resources/Prototypes/Actions/station_ai.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,3 +66,16 @@
state: state_laws
event: !type:ToggleLawsScreenEvent
useDelay: 0.5

- type: entity
id: ActionAIShowCriminalRecords
name: Criminal Records Interface
description: View a criminal records Interface.
components:
- type: InstantAction
icon: { sprite: Interface/Actions/actions_ai.rsi, state: station_records }
iconOn: Interface/Actions/actions_ai.rsi/station_records.png
keywords: [ "AI", "console", "interface" ]
priority: -8
event: !type:ToggleIntrinsicUIEvent { key: enum.CriminalRecordsConsoleKey.Key }

10 changes: 5 additions & 5 deletions Resources/Prototypes/Entities/Mobs/Player/silicon.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@
type: RadarConsoleBoundUserInterface
enum.CrewMonitoringUIKey.Key:
type: CrewMonitoringBoundUserInterface
enum.GeneralStationRecordConsoleKey.Key:
type: GeneralStationRecordConsoleBoundUserInterface
enum.CriminalRecordsConsoleKey.Key:
type: CriminalRecordsConsoleBoundUserInterface
enum.SiliconLawsUiKey.Key:
type: SiliconLawBoundUserInterface
enum.CommunicationsConsoleUiKey.Key:
Expand All @@ -54,12 +54,12 @@
toggleAction: ActionAGhostShowRadar
enum.CrewMonitoringUIKey.Key:
toggleAction: ActionAGhostShowCrewMonitoring
enum.GeneralStationRecordConsoleKey.Key:
toggleAction: ActionAGhostShowStationRecords
enum.CriminalRecordsConsoleKey.Key:
toggleAction: ActionAIShowCriminalRecords
enum.CommunicationsConsoleUiKey.Key:
toggleAction: ActionAGhostShowCommunications
- type: CrewMonitoringConsole
- type: GeneralStationRecordConsole
- type: CriminalRecordsConsole
- type: DeviceNetwork
deviceNetId: Wireless
receiveFrequencyId: CrewMonitor
Expand Down

0 comments on commit d927a6f

Please sign in to comment.