Skip to content

Better handheld radios - #269

Open
mycobiota wants to merge 29 commits into
funky-station:masterfrom
mycobiota:walkie-talkie-mic-toggle
Open

Better handheld radios#269
mycobiota wants to merge 29 commits into
funky-station:masterfrom
mycobiota:walkie-talkie-mic-toggle

Conversation

@mycobiota

@mycobiota mycobiota commented Aug 4, 2026

Copy link
Copy Markdown

About the PR

greatly expanded upon the functionality of handheld radios. you are now able to listen to a radio without having to switch on its microphone, and you can toggle them hands free from the action hotbar now. you are also able to adjust their volume (whisper volume vs full volume) and listening range (by default, from 1 to 4) via a UI. the microphone also now makes a sound when toggled on and off.
the microphone and speaker on / off states can be seen when examining the radio now, too. intercoms inherit this feature.

Why / Balance

as it stands, the handheld radios we have upstream kinda suck if you try to actually make use of them. to listen to one, you have to be broadcasting the mic, which is really awkward sometimes when there are many people nearby. since the listening range on them is fucking huge, you end up spamming the radio's channel with random messages.

the goal with this is to try and make them more broadly usable while keeping them distinct from headsets, since i think they are fun and flavorful items which should be expanded on (for example, by adding departmental handheld radios).

the speaker volume and sensitivity/listening range are tied together. this is an intentional limitation, the idea being that if it is listening beyond the range at which whispering is audible, it shouldnt be speaking at a whisper volume. think of setting the sensitivity/volume beyond 2 like "putting it on speakerphone".
default max range is 4 because thats what the upstream listen range is.

Technical details

this PR is an expansion on RadioMicrophone and RadioSpeaker and their associated systems.
Server-side RadioDeviceSystem checks between RadioMicrophone and RadioSpeaker to only toggle on one or the other. it also handles updating volume and listen range when these are adjusted via UI, and examine markup has also been expanded on.
SharedRadioDeviceSystem now also handles verbs and actions and cooldowns for toggling the speaker and microphone.
UI code has been added. the two radio components are handled separately, so the UI works even if only one of them are present.

Test plan

Mess around with two handheld radios. make sure to also test their volume UI. make sure intercoms work as usual and display the on/off state examine text. use VV to change the max and min range and make sure that the UI accommodates this when you reopen it.
also mess around with security radios to make sure that children of the base handheld radio work fine.
Also see how handheld radios without speakers / mics behave, and how a speaker (non-intercom) with multiple channels behaves. Some testing items have been added for this.

Media

test1.mp4
test2.mp4
test3.mp4
Screenshot_20260804_142339

Requirements

  • I have read and am following the Macrocosm Pull Request Conventions.
  • I have tested this pull request and written instructions on how to test it
  • I have added media to this PR or it does not require an in-game showcase.
  • If I am porting something, I have done my best to respect the appropriate licenses associated with the presented changes.

License

MIT

Breaking changes

all you need to do to add new handheld radios with all of these features is to inherit from RadioHandheld.
anything that already uses the radiomicrophone or radiospeaker components has not been broken nor do they need to be updated. intercoms work exactly the same as before, save for some new examine text.

if you want to remove most of the new features from RadioHandheld, you just need to remove the new fields, UI and UseDelay, which have been marked.
anything that has both radio components will be able to toggle their speaker and mic separately, including being able to turn on the mic without turning on the speaker, unless you specify speakerRequired: true on the mic.

the OnActivateMicrophone and OnActivateSpeaker functions subscribed to ActivateInWorldEvent have been moved to Shared.

Changelog

🆑

  • add: Handheld radios now have toggleable mics, sound effects, and an adjustable volume and mic sensitivity.

@mycobiota
mycobiota marked this pull request as ready for review August 4, 2026 22:21
@mycobiota

Copy link
Copy Markdown
Author

i went ahead and checked, works fine with #85 and #262.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant