From ac1d06e312c5c09b81051ade7f59aaeead59d6d8 Mon Sep 17 00:00:00 2001 From: ike709 Date: Sun, 7 Mar 2021 18:15:51 -0600 Subject: [PATCH] Adds a latejoin radio announcement (#3569) Co-authored-by: ike709 --- Content.Server/GameTicking/GameTicker.cs | 10 ++++++++++ Resources/Locale/en-US/centcomm.ftl | 3 +++ 2 files changed, 13 insertions(+) create mode 100644 Resources/Locale/en-US/centcomm.ftl diff --git a/Content.Server/GameTicking/GameTicker.cs b/Content.Server/GameTicking/GameTicker.cs index 27da6a7d8c..3d656da95d 100644 --- a/Content.Server/GameTicking/GameTicker.cs +++ b/Content.Server/GameTicking/GameTicker.cs @@ -2,6 +2,7 @@ using System.Collections.Generic; using System.Collections.Immutable; using System.Diagnostics.CodeAnalysis; +using System.Globalization; using System.Linq; using System.Reflection; using System.Threading; @@ -897,6 +898,15 @@ namespace Content.Server.GameTicking var job = new Job(data.Mind, jobPrototype); data.Mind.AddRole(job); + if (lateJoin) + { + _chatManager.DispatchStationAnnouncement(Loc.GetString( + "latejoin-arrival-announcement", + ("character", character.Name), + ("job", CultureInfo.CurrentCulture.TextInfo.ToTitleCase(job.Name)) + )); + } + var mob = _spawnPlayerMob(job, character, lateJoin); data.Mind.TransferTo(mob); diff --git a/Resources/Locale/en-US/centcomm.ftl b/Resources/Locale/en-US/centcomm.ftl new file mode 100644 index 0000000000..beb82d40e1 --- /dev/null +++ b/Resources/Locale/en-US/centcomm.ftl @@ -0,0 +1,3 @@ +### Automated Centcomm announcements + +latejoin-arrival-announcement = {$character} ({$job}) has arrived at the station!