diff --git a/Content.Server/TapeRecorder/TapeRecorderSystem.cs b/Content.Server/TapeRecorder/TapeRecorderSystem.cs index f6e8b7ee77..44e625d3e3 100644 --- a/Content.Server/TapeRecorder/TapeRecorderSystem.cs +++ b/Content.Server/TapeRecorder/TapeRecorderSystem.cs @@ -12,6 +12,7 @@ using Robust.Shared.Prototypes; using Robust.Shared.Timing; using System.Text; +using Content.Shared.Backmen.Chat; namespace Content.Server.TapeRecorder; @@ -34,7 +35,10 @@ public override void Initialize() /// Given a time range, play all messages on a tape within said range, [start, end). /// Split into this system as shared does not have ChatSystem access /// - protected override void ReplayMessagesInSegment(Entity ent, TapeCassetteComponent tape, float segmentStart, float segmentEnd) + protected override void ReplayMessagesInSegment(Entity ent, + TapeCassetteComponent tape, + float segmentStart, + float segmentEnd) { var voice = EnsureComp(ent); var speech = EnsureComp(ent); @@ -79,7 +83,10 @@ private void OnListen(Entity ent, ref ListenEvent args) //Add a new entry to the tape var verb = _chat.GetSpeechVerb(args.Source, args.Message); var name = nameEv.VoiceName; - cassette.Comp.Buffer.Add(new TapeCassetteRecordedMessage(cassette.Comp.CurrentPosition, name, verb, args.Message)); + cassette.Comp.Buffer.Add(new TapeCassetteRecordedMessage(cassette.Comp.CurrentPosition, + name, + verb, + args.Message)); } private void OnPrintMessage(Entity ent, ref PrintTapeRecorderMessage args) @@ -98,7 +105,7 @@ private void OnPrintMessage(Entity ent, ref PrintTapeReco // Sorting list by time for overwrite order // TODO: why is this needed? why wouldn't it be stored in order var data = cassette.Comp.RecordedData; - data.Sort((x,y) => x.Timestamp.CompareTo(y.Timestamp)); + data.Sort((x, y) => x.Timestamp.CompareTo(y.Timestamp)); // Looking if player's entity exists to give paper in its hand var player = args.Actor; @@ -115,13 +122,14 @@ private void OnPrintMessage(Entity ent, ref PrintTapeReco foreach (var message in cassette.Comp.RecordedData) { var name = message.Name ?? ent.Comp.DefaultName; - var time = TimeSpan.FromSeconds((double) message.Timestamp); + var time = TimeSpan.FromSeconds((double)message.Timestamp); text.AppendLine(Loc.GetString("tape-recorder-print-message-text", ("time", time.ToString(@"hh\:mm\:ss")), ("source", name), ("message", message.Message))); } + text.AppendLine(); text.Append(Loc.GetString("tape-recorder-print-end-text"));