Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve radio scanning experience, make it more likely there will be radios in range #59550

Merged
merged 1 commit into from
Jul 29, 2022

Conversation

anothersimulacrum
Copy link
Member

Summary

Content "Increase range of radios and improve radio scanning experience"

Purpose of change

I've noticed we have this feature from poking around in the code, but every time I've tried to use it, there haven't been any radios in range.
Radios appear largely unchanged since #731

Describe the solution

This commit does 4 things:

  1. Increase both the min and max range of radios, so there's a greater chance a radio will be in range. Numbers semi-arbitrary.
  2. Add a debugmode filter for radio, so I can add some debugging messages for it.
  3. Save radio frequency, so your radio doesn't lose it's selected frequency every time you reload.
  4. Make radio scanning better, and modify how noise is applied to radio messages.

While the current scanning is perhaps a little immersive, in actual use it's quite annoying and, because it gives no feedback, it's hard to tell if it actually did anything.
Replace this with a list of stations in range that you can select from, with a little descriptor describing how much noise there is (the reason for the modification of the noise). Messages are snippets to enable multiple options and ease of editing.

Describe alternatives you've considered

Keeping the current scanning, but giving some feedback. Different values for range.

Testing

Spawn in a radio, give it a battery. Activate it and scan for radios. Select a choice, and scan again, see it is still selected. Save and load, then scan again and see the station you previously selected is still selected.
image

Additional context

The range increase only applies to newly generated radio sources.

@github-actions github-actions bot added [C++] Changes (can be) made in C++. Previously named `Code` [JSON] Changes (can be) made in JSON Lore Game lore, in-game communication. Also the Lore tab. Map / Mapgen Overmap, Mapgen, Map extras, Map display json-styled JSON lint passed, label assigned by github actions astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions labels Jul 24, 2022
I've noticed we have this feature from poking around in the code, but
every time I've tried to use it, there haven't been any radios in range.

This commit does 4 things:
1. Increase both the min and max range of radios, so there's a greater
   chance a radio will be in range. Numbers semi-arbitrary.
2. Add a debugmode filter for radio, so I can add some debugging
   messages for it.
3. Save radio frequency, so your radio doesn't lose it's selected
   frequency every time you reload.
4. Make radio scanning better, and modify how noise is applied to radio
   messages.

While the current scanning is perhaps a little immersive, in actual use
it's quite annoying and, because it gives no feedback, it's hard to tell
if it actually did anything. Replace this with a list of stations in
range that you can select from, with a little descriptor describing how
much noise there is (the reason for the modification of the noise).
Messages are snippets to enable multiple options and ease of editing.
@dseguin dseguin merged commit 64a3ef7 into CleverRaven:master Jul 29, 2022
@anothersimulacrum anothersimulacrum deleted the all-i-hear branch July 29, 2022 02:56
int static_roll = dice( 10, 100 );
if( static_roll > signal_roll )
const city *c = overmap_buffer.closest_city( tripoint_abs_sm( tref.abs_sm_pos, 0 ) ).city;
const std::string cityname = c == nullptr ? "ksssh" : c->name;
Copy link
Contributor

Choose a reason for hiding this comment

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

Looks like this is a onomatopoeia, it should probably be translated.

Copy link
Member Author

Choose a reason for hiding this comment

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

Yep, my bad.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions [C++] Changes (can be) made in C++. Previously named `Code` [JSON] Changes (can be) made in JSON json-styled JSON lint passed, label assigned by github actions Lore Game lore, in-game communication. Also the Lore tab. Map / Mapgen Overmap, Mapgen, Map extras, Map display
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants