diff --git a/Content.Server/Ghost/Components/GhostRadioComponent.cs b/Content.Server/Ghost/Components/GhostRadioComponent.cs
index 981ff49775..ab1ffa0524 100644
--- a/Content.Server/Ghost/Components/GhostRadioComponent.cs
+++ b/Content.Server/Ghost/Components/GhostRadioComponent.cs
@@ -7,15 +7,30 @@ using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom.Prototy
namespace Content.Server.Ghost.Components
{
+ ///
+ /// Add to a particular entity to let it receive messages from the specified channels.
+ ///
[RegisterComponent]
[ComponentReference(typeof(IRadio))]
public sealed class GhostRadioComponent : Component, IRadio
{
+ // TODO: This class is yuck
[Dependency] private readonly IServerNetManager _netManager = default!;
[Dependency] private readonly IEntityManager _entMan = default!;
[DataField("channels", customTypeSerializer: typeof(PrototypeIdHashSetSerializer))]
- private HashSet _channels = new();
+ private HashSet _channels = new()
+ {
+ "Common",
+ "Command",
+ "CentCom",
+ "Engineering",
+ "Medical",
+ "Science",
+ "Security",
+ "Service",
+ "Supply",
+ };
public void Receive(string message, RadioChannelPrototype channel, EntityUid speaker)
{
@@ -29,7 +44,7 @@ namespace Content.Server.Ghost.Components
Channel = ChatChannel.Radio,
Message = message,
//Square brackets are added here to avoid issues with escaping
- MessageWrap = Loc.GetString("chat-radio-message-wrap", ("channel", $"\\[{channel.Name}\\]"), ("name", _entMan.GetComponent(speaker).EntityName))
+ MessageWrap = Loc.GetString("chat-radio-message-wrap", ("color", channel.Color), ("channel", $"\\[{channel.Name}\\]"), ("name", _entMan.GetComponent(speaker).EntityName))
};
_netManager.ServerSendMessage(msg, playerChannel);
diff --git a/Resources/Prototypes/radio_channels.yml b/Resources/Prototypes/radio_channels.yml
index 8fd7bfb1d2..e31cc44684 100644
--- a/Resources/Prototypes/radio_channels.yml
+++ b/Resources/Prototypes/radio_channels.yml
@@ -3,64 +3,67 @@
name: "Common"
keycode: ";"
frequency: 1459
+ color: "#1ecc43"
- type: radioChannel
id: CentCom
name: "CentCom"
keycode: 'y'
frequency: 1337
+ color: "#2681a5"
- type: radioChannel
id: Command
name: "Command"
keycode: 'c'
frequency: 1353
- color: "#334e6d"
+ color: "#fcdf03"
- type: radioChannel
id: Engineering
name: "Engineering"
keycode: 'e'
frequency: 1357
- color: "#efb341"
+ color: "#f37746"
- type: radioChannel
id: Medical
name: "Medical"
keycode: 'm'
frequency: 1355
- color: "#52b4e9"
+ color: "#57b8f0"
- type: radioChannel
id: Science
name: "Science"
keycode: 'n'
frequency: 1351
- color: "#d381c9"
+ color: "#c68cfa"
- type: radioChannel
id: Security
name: "Security"
keycode: 's'
frequency: 1359
- color: "#de3a3a"
+ color: "#dd3535"
- type: radioChannel
id: Service
name: "Service"
keycode: 'v'
frequency: 1349
- color: "#9fed58"
+ color: "#6ca729"
- type: radioChannel
id: Supply
name: "Supply"
keycode: 'u'
frequency: 1347
- color: "#a46106"
+ color: "#b88646"
- type: radioChannel
id: Syndicate
name: "Syndicate"
keycode: 't'
frequency: 1213
+ color: "#8f4a4b"