Skip to content

Commit

Permalink
Always hide ghost range limit chat from ghosts
Browse files Browse the repository at this point in the history
This fixes radios with speakers spamming ghost chat.
  • Loading branch information
Partmedia committed Nov 5, 2024
1 parent da11793 commit 6327ebe
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Content.Server/Chat/Systems/ChatSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -686,7 +686,8 @@ private MessageRangeCheckResult MessageRangeCheck(ICommonSession session, ICChat
initialResult = MessageRangeCheckResult.Full;
break;
case ChatTransmitRange.GhostRangeLimit:
initialResult = (data.Observer && data.Range < 0 && !_adminManager.IsAdmin(session)) ? MessageRangeCheckResult.HideChat : MessageRangeCheckResult.Full;
// N14: Always hide this from ghosts to avoid multiple radios spamming the ghost chat.
initialResult = data.Observer ? MessageRangeCheckResult.HideChat : MessageRangeCheckResult.Full;
break;
case ChatTransmitRange.HideChat:
initialResult = MessageRangeCheckResult.HideChat;
Expand Down

0 comments on commit 6327ebe

Please sign in to comment.