Skip to content

fix(speech): stop speech with Control in menus and help reader#26

Merged
Orinks merged 1 commit into
Orinks:devfrom
liamerven:fix/menu-stop-speech
Jul 1, 2026
Merged

fix(speech): stop speech with Control in menus and help reader#26
Orinks merged 1 commit into
Orinks:devfrom
liamerven:fix/menu-stop-speech

Conversation

@liamerven

Copy link
Copy Markdown

What changed and why

Left or Right Control already stopped the driving event voice, but menus and the how-to-play reader speak on the main channel, so pressing Control there did nothing. A long readout -- job details, cargo loading, a full help page -- could not be cut short.

This adds GameContext.stop_speech() (silences both channels) and wires Control to it in the shared MenuState base class and the HelpState reader, so the same key now stops speech everywhere in the game.

What players/maintainers will notice

  • In any menu (and the how-to-play reader), Left or Right Control now stops the current speech, matching how it already works while driving.
  • The stop key is documented in the menu intro help (F1) and the help reader intro.

Tests / checks run

  • New tests/test_menu_stop_speech.py covers the menu key, the help-reader key, and that stop_speech() quiets both channels.
  • uv run pytest (focused: menu/controls/speech/driving suites), uv run ruff check src tests tools, uv run python -m compileall src tests tools -- all pass. pre-commit hooks pass.

Accessibility impact

Directly improves screen-reader UX: a verbose menu readout (e.g. the cargo loading screen) can now be silenced instantly with a familiar key, instead of forcing the player to wait it out. No visual-only cues introduced; spoken behavior only.

🤖 Generated with Claude Code

Left or Right Control silenced only the driving event voice. Menus and the
how-to-play reader speak on the main channel, so a long readout (job details,
cargo loading, a full help page) could not be cut short. Add a GameContext
stop_speech() that quiets both channels, wire Control to it in the menu base
class and the help reader, document the key, and cover it with tests.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@Orinks Orinks merged commit 4762d30 into Orinks:dev Jul 1, 2026
4 checks passed
@liamerven liamerven deleted the fix/menu-stop-speech branch July 1, 2026 13:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants