Intercom buffs and fixes (#29580)

* Intercom buffs and fixes

* remove unused bui state

* mild sec intercom buff

* reinforce sec intercoms
This commit is contained in:
Nemanja
2024-07-07 10:19:10 -04:00
committed by GitHub
parent 063c5de985
commit 0e9ed36b85
22 changed files with 338 additions and 136 deletions

View File

@@ -1,23 +1,32 @@
using Robust.Shared.GameStates;
using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom.Prototype.List;
using Robust.Shared.Prototypes;
namespace Content.Shared.Radio.Components;
/// <summary>
/// Handles intercom ui and is authoritative on the channels an intercom can access.
/// </summary>
[RegisterComponent, NetworkedComponent]
[RegisterComponent, NetworkedComponent, AutoGenerateComponentState(true)]
public sealed partial class IntercomComponent : Component
{
/// <summary>
/// Does this intercom require popwer to function
/// Does this intercom require power to function
/// </summary>
[DataField("requiresPower"), ViewVariables(VVAccess.ReadWrite)]
[DataField]
public bool RequiresPower = true;
[DataField, AutoNetworkedField]
public bool SpeakerEnabled;
[DataField, AutoNetworkedField]
public bool MicrophoneEnabled;
[DataField, AutoNetworkedField]
public ProtoId<RadioChannelPrototype>? CurrentChannel;
/// <summary>
/// The list of radio channel prototypes this intercom can choose between.
/// </summary>
[DataField("supportedChannels", customTypeSerializer: typeof(PrototypeIdListSerializer<RadioChannelPrototype>))]
public List<string> SupportedChannels = new();
[DataField, AutoNetworkedField]
public List<ProtoId<RadioChannelPrototype>> SupportedChannels = new();
}