Skip to content

Loudmode: Yapping Edition - #5395

Merged
Rinary1 merged 18 commits into
ss14Starlight:starlight-devfrom
Spaghetti-bit:LoudMode
Aug 11, 2026
Merged

Loudmode: Yapping Edition#5395
Rinary1 merged 18 commits into
ss14Starlight:starlight-devfrom
Spaghetti-bit:LoudMode

Conversation

@Spaghetti-bit

@Spaghetti-bit Spaghetti-bit commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Short description

Adds loudmode to command headsets and some outlier commanding headsets.
Accessible by right click the headset.

Why we need to add this

During cluttered and hectic moments, the boldened text will make it easier to read.

Media (Video/Screenshots)

Headsets with loud mode:
image

UI Verb:
image

Inactive:
image

Active:
image

Loudmode active, common (with chat width @ 350):
image

In active:
image

Yelling / Screaming:
image

Checks

  • I do not require assistance to complete the PR.
  • Before posting/requesting review of a PR, I have verified that the changes work.
  • I have added screenshots/videos of the changes, or this PR does not change in-game mechanics.
  • I affirm that my changes are licensed under the MIT License and grant permission for use in this repository under its conditions.

Changelog
🆑 Spaghetti-Bit

  • add: Added loud mode to command headsets, as well as some other commanding role headsets.
  • add: Yelling will now make your message more noticeable on the radio.

@Spaghetti-bit
Spaghetti-bit requested a review from a team July 29, 2026 12:49
@github-actions github-actions Bot added size/M S: Needs Review Status: Requires additional reviews before being fully accepted. Not to be replaced by S: Approved. S: Untriaged Status: Indicates an item has not been triaged and doesn't have appropriate labels. Changes: C# Changes: Prototypes labels Jul 29, 2026
@coderabbitai

coderabbitai Bot commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

Changes

Headset loud mode

Layer / File(s) Summary
Loud-mode component and interaction
Content.Shared/..., Resources/Locale/..., Resources/Prototypes/...
Adds the networked HeadsetLoudModeComponent, examination status, toggle verb, localization, and loud-mode support to affected headset prototypes.
Loud-mode radio propagation
Content.Server/Radio/EntitySystems/..., Resources/Prototypes/Voice/speech_verbs.yml
Reads the active loud-mode state during speech and passes it through standard and custom radio wrapping. DefaultExclamationStrong uses font size 14.

The change adds a complete loud-mode flow from headset interaction to radio message formatting. The implementation includes the required component, prototype wiring, localization, and radio propagation.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Suggested reviewers: redmushie

Sequence Diagram(s)

sequenceDiagram
  participant Speaker
  participant HeadsetSystem
  participant RadioSystem
  participant MessageWrapper
  Speaker->>HeadsetSystem: Speak through headset
  HeadsetSystem->>RadioSystem: Send message with loud mode
  RadioSystem->>MessageWrapper: Wrap standard or custom radio message
  MessageWrapper-->>RadioSystem: Apply loud-mode font sizing
Loading
🚥 Pre-merge checks | ✅ 7 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
No Magic Numbers ⚠️ Warning The feature is well structured, but HeadsetLoudModeComponent.cs:17 uses the meaningful default FontSize = 4 without a named constant. Define a clearly named constant such as DefaultFontSize = 4 and initialize FontSize from it.
✅ Passed checks (7 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
No Hardcoded Ecs Parameters ✅ Passed The implementation cleanly reads loud-mode sizing from HeadsetLoudModeComponent.FontSize, which is a DataField with a default; no loud-mode numeric value is hardcoded in the systems.
Avoid Service Locator ✅ Passed Good dependency handling: the new localization calls use EntitySystem's injected ILocalizationManager Loc, and the feature diff adds no IoCManager.Resolve or other service-locator access.
Title check ✅ Passed The title identifies the loud mode feature, which is the main change in the pull request.
Description check ✅ Passed The description explains loud mode, affected headsets, user access, purpose, and included behavior.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@Content.Server/Radio/EntitySystems/HeadsetSystem.cs`:
- Line 75: Update the _radio.SendCustomRadioMessage call in HeadsetSystem to
pass loudMode as the named loudMode argument, ensuring it is not bound to
escapeMarkup and that user text remains correctly escaped while loud mode
activates.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI (base), Organization UI (inherited)

Review profile: CHILL

Plan: Pro Plus

Run ID: 97333c7e-d4e5-4ed9-8616-c7bec833ecbe

📥 Commits

Reviewing files that changed from the base of the PR and between cfaef58 and 0f126fe.

📒 Files selected for processing (10)
  • Content.Server/Radio/EntitySystems/HeadsetSystem.cs
  • Content.Server/Radio/EntitySystems/RadioSystem.cs
  • Content.Shared/Radio/EntitySystems/SharedHeadsetSystem.cs
  • Content.Shared/_Starlight/Clothing/HeadsetLoudModeComponent.cs
  • Resources/Locale/en-US/_Starlight/ui/verbs.ftl
  • Resources/Locale/en-US/headset/headset-component.ftl
  • Resources/Prototypes/Entities/Clothing/Ears/headsets.yml
  • Resources/Prototypes/Entities/Clothing/Ears/headsets_alt.yml
  • Resources/Prototypes/_Starlight/Entities/Clothing/Ears/headsets.yml
  • Resources/Prototypes/_Starlight/Entities/Clothing/Ears/headsets_alt.yml

Comment thread Content.Server/Radio/EntitySystems/HeadsetSystem.cs Outdated
coderabbitai[bot]
coderabbitai Bot previously approved these changes Jul 29, 2026
@coderabbitai

coderabbitai Bot commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Note

The previously reviewed commits are no longer reachable (likely due to a force-push or rebase), so CodeRabbit is performing a full review instead of an incremental one. This review may take a little longer.

@Conflee

Conflee commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Does this work with all languages? There used to be a feature that bolded when someone yelled, but it was removed for lack of font support for language fonts.

If just, scaling the font up works, I would LOVE a less-large version of this for any time anyone yells (using exclamation marks to end sentences) to revive that old feature a little.

@Spaghetti-bit

Copy link
Copy Markdown
Contributor Author

Does this work with all languages? There used to be a feature that bolded when someone yelled, but it was removed for lack of font support for language fonts.

I haven't been able to test it for languages that aren't understood, but I know that if you understand them, it works just fine. If anything I can just make a TTF for the font that's the same as the original.

If just, scaling the font up works, I would LOVE a less-large version of this for any time anyone yells (using exclamation marks to end sentences) to revive that old feature a little.

It's possible but out of scope

@redmushie redmushie left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

First off -- nice PR! I've missed yelling.

However, I have to give it to the other commenters. Re-introducing the "Scream!!" mechanic where (I believe two or more?) exclamation points turn something into yelling simply by increasing the font size is a lot more universal. It doesn't preclude non-Command players.

In addition, the yelling mechanic of old doesn't require new toggles, which is the biggest differentiator for me. It makes for a much simpler user experience.

As such I'm rejecting the PR in its current state. If you are willing to change to said approach I'd be more than happy to review it.

@starlightgithub starlightgithub Bot added S: Awaiting Changes Status: Changes are required before another review can happen and removed S: Needs Review Status: Requires additional reviews before being fully accepted. Not to be replaced by S: Approved. labels Jul 31, 2026
@redmushie redmushie self-assigned this Jul 31, 2026
@Spaghetti-bit

Copy link
Copy Markdown
Contributor Author

As such I'm rejecting the PR in its current state. If you are willing to change to said approach I'd be more than happy to review it.

Perfectly willing. I'll add an increase of font size based off of how loud someone is. One exclamation for two font size increases, and two for four sizes increase.

Or something along those lines.

@Spaghetti-bit

Copy link
Copy Markdown
Contributor Author
image

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@Resources/Prototypes/Voice/speech_verbs.yml`:
- Line 38: Update the fontSize values for DefaultExclamation and
DefaultExclamationStrong so they explicitly use 14 and 16 respectively,
preserving the required two-point increase per exclamation level.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI (base), Organization UI (inherited)

Review profile: CHILL

Plan: Pro Plus

Run ID: 99caf8a9-55a1-4ca7-876f-d751ce13a0bd

📥 Commits

Reviewing files that changed from the base of the PR and between 020fd71 and 0036c7e.

📒 Files selected for processing (3)
  • Content.Server/Radio/EntitySystems/RadioSystem.cs
  • Resources/Locale/en-US/headset/headset-component.ftl
  • Resources/Prototypes/Voice/speech_verbs.yml
🚧 Files skipped from review as they are similar to previous changes (2)
  • Resources/Locale/en-US/headset/headset-component.ftl
  • Content.Server/Radio/EntitySystems/RadioSystem.cs

Comment thread Resources/Prototypes/Voice/speech_verbs.yml Outdated

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
Content.Server/Radio/EntitySystems/RadioSystem.cs (1)

480-488: 🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

Preserve the language font baseline in both wrappers.

When loudComp is present, both expressions use loudComp.FontSize + speech.FontSize and discard language.Speech.FontSize.

  • Content.Server/Radio/EntitySystems/RadioSystem.cs#L480-L488: resolve the normal or yelling base size first, then add loudComp.FontSize.
  • Content.Server/Radio/EntitySystems/RadioSystem.cs#L522-L530: apply the same calculation to custom radio messages.
Proposed fix
-        return Loc.GetString(... ("fontSize", loudComp is not null ? loudComp.FontSize + speech.FontSize : isYelling ? speech.FontSize : language.Speech.FontSize ?? speech.FontSize), ...);
+        var fontSize = isYelling ? speech.FontSize : language.Speech.FontSize ?? speech.FontSize;
+        if (loudComp is not null)
+            fontSize += loudComp.FontSize;
+
+        return Loc.GetString(... ("fontSize", fontSize), ...);
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@Content.Server/Radio/EntitySystems/RadioSystem.cs` around lines 480 - 488,
The font-size calculation in both RadioSystem message wrappers must preserve the
language baseline when loud mode is active. At
Content.Server/Radio/EntitySystems/RadioSystem.cs lines 480-488, resolve the
normal-or-yelling base size first, then add loudComp.FontSize; apply the same
calculation at lines 522-530 for custom radio messages.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Outside diff comments:
In `@Content.Server/Radio/EntitySystems/RadioSystem.cs`:
- Around line 480-488: The font-size calculation in both RadioSystem message
wrappers must preserve the language baseline when loud mode is active. At
Content.Server/Radio/EntitySystems/RadioSystem.cs lines 480-488, resolve the
normal-or-yelling base size first, then add loudComp.FontSize; apply the same
calculation at lines 522-530 for custom radio messages.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI (base), Organization UI (inherited)

Review profile: CHILL

Plan: Pro Plus

Run ID: 68d60eb8-ccac-491b-a575-9cd880cae51a

📥 Commits

Reviewing files that changed from the base of the PR and between 0036c7e and 8bd334f.

📒 Files selected for processing (5)
  • Content.Server/Radio/EntitySystems/HeadsetSystem.cs
  • Content.Server/Radio/EntitySystems/RadioSystem.cs
  • Content.Shared/_Starlight/Clothing/HeadsetLoudModeComponent.cs
  • Resources/Locale/en-US/headset/headset-component.ftl
  • Resources/Prototypes/Voice/speech_verbs.yml
💤 Files with no reviewable changes (1)
  • Resources/Locale/en-US/headset/headset-component.ftl
🚧 Files skipped from review as they are similar to previous changes (3)
  • Resources/Prototypes/Voice/speech_verbs.yml
  • Content.Server/Radio/EntitySystems/HeadsetSystem.cs
  • Content.Shared/_Starlight/Clothing/HeadsetLoudModeComponent.cs

coderabbitai[bot]
coderabbitai Bot previously approved these changes Aug 1, 2026
@mikeysaurus

mikeysaurus commented Aug 1, 2026

Copy link
Copy Markdown
Member

Refactored to have the fontsize increase be tied to the headsetloud comp. Which means it can be set in .yml with ease.
...
Means that you could have certain headsets be louder than others or have an EMAG act / sabotage to make it louder or quieter.

Looks better to me! thanks
image

@coderabbitai coderabbitai Bot mentioned this pull request Aug 5, 2026
4 tasks
Comment thread Content.Server/Radio/EntitySystems/HeadsetSystem.cs Outdated
Comment thread Content.Server/Radio/EntitySystems/HeadsetSystem.cs Outdated
Comment thread Content.Server/Radio/EntitySystems/RadioSystem.cs Outdated
Comment thread Resources/Locale/en-US/headset/headset-component.ftl Outdated
@starlightgithub starlightgithub Bot added S: Awaiting Changes Status: Changes are required before another review can happen and removed S: Needs Review Status: Requires additional reviews before being fully accepted. Not to be replaced by S: Approved. labels Aug 10, 2026
@github-actions github-actions Bot added S: Needs Review Status: Requires additional reviews before being fully accepted. Not to be replaced by S: Approved. and removed S: Awaiting Changes Status: Changes are required before another review can happen labels Aug 10, 2026
@starlightgithub starlightgithub Bot added S: Approved Status: Reviewed and approved by at least one maintainer or dev; a PR may require another approval. and removed S: Needs Review Status: Requires additional reviews before being fully accepted. Not to be replaced by S: Approved. labels Aug 11, 2026
@Rinary1
Rinary1 added this pull request to the merge queue Aug 11, 2026
Merged via the queue into ss14Starlight:starlight-dev with commit 92bc6f6 Aug 11, 2026
26 checks passed
starlightgithub Bot added a commit that referenced this pull request Aug 11, 2026
@coderabbitai coderabbitai Bot mentioned this pull request Aug 14, 2026
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Changes: C# Changes: Prototypes S: Approved Status: Reviewed and approved by at least one maintainer or dev; a PR may require another approval. S: Untriaged Status: Indicates an item has not been triaged and doesn't have appropriate labels. size/M

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants