Fix SpeakOnTrigger not working for messages starting with '.' (#36053)

This commit is contained in:
Tayrtahn
2025-03-24 14:19:29 -04:00
committed by GitHub
parent c9f567956a
commit 67b76d81e5

View File

@@ -34,6 +34,10 @@ public sealed class SpeakOnTriggerSystem : EntitySystem
return;
var message = Loc.GetString(_random.Pick(messagePack.Values));
// Chatcode moment: messages starting with "." are considered radio messages.
// Prepending ">" forces the message to be spoken instead.
// TODO chat refactor: remove this
message = '>' + message;
_chat.TrySendInGameICMessage(ent.Owner, message, InGameICChatType.Speak, true);
if (useDelay != null)