ワンクリックで
narrator-management
This skill should be used when managing the Bamboozle narrator system, including premium voices and Safari compatibility.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
This skill should be used when managing the Bamboozle narrator system, including premium voices and Safari compatibility.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
This skill should be used when managing, building, and troubleshooting the Capacitor-based Android application for Bamboozle.
This skill should be used when generating, managing, and exporting branding assets for Bamboozle.
This skill should be used when adding a new game action or event to the Bamboozle codebase.
This skill should be used when writing or updating documentation, coding standards, and best practices for the Bamboozle codebase.
This skill should be used when adding or modifying a game phase (e.g., adding a 'Wager' phase) in Bamboozle.
| name | narrator-management |
| description | This skill should be used when managing the Bamboozle narrator system, including premium voices and Safari compatibility. |
| version | 1.0.0 |
| author | Gabriel Athanasiou |
| created | "2024-05-01T00:00:00.000Z" |
| updated | "2026-03-07T00:00:00.000Z" |
| platforms | ["copilot","claude","codex"] |
| category | development |
| tags | ["audio","narrator","tts"] |
| risk | safe |
The Bamboozle narrator is a critical part of the game's personality. This skill explains how to modify narrator behavior, add new voice lines, and maintain the complex audio subsystem.
The audio system (services/audioService.ts & gameService.ts) handles two types of audio:
speechSynthesis fallback.To play audio on iOS Safari without a user gesture for every line, use a Shared Audio Element strategy:
<audio> element (narratorAudioRef in gameService.ts) is created.src of this exact same element.⚠️ NEVER create a new Audio() instance for the narrator in the game loop. Always reuse the ref.
Narrator lines are stored in i18n/narrator/.
i18n/narrator/en.ts (or el.ts)Steps:
GREETINGS, REVEAL_LIE, GAME_OVER).{player} or {points} placeholders if the code supports them.Example:
// i18n/narrator/en.ts
export const NARRATOR_EN = {
// ...
GENERIC_PRAISE: [
"Not bad, human.",
"I've seen worse.",
"Impressive... for a meatbag." // New line
],
// ...
};
services/gameService.tsUse the speak() function to trigger narration. It automatically handles:
usePremiumVoices).Design Pattern:
// inside gameService.ts or a component with access to actions
speak("Welcome to Bamboozle!", true); // true = force interrupt
Using Localized Lines:
// helper to get random line
const line = getNarratorPhrase(state.language, 'GENERIC_PRAISE', {});
speak(line);
The Android app runs in a WebView. While it behaves similarly to Chrome, there are native considerations:
http://localhost:3001 will fail on Android. You must use the local IP (e.g., http://192.168.x.x:3001).android:usesCleartextTraffic="true" to load audio from non-HTTPS sources during development.unlockAudio() was called. Verify narratorAudioRef.current is being used.ProgressionManager waits for onAudioEnded. If the audio errors out and does not fire ended, the game hangs.
playNextPremium (gameService.ts) is active (currently set to ~8s).server/index.js (or server/tts.ts).i18n/narrator.speak() called with correct localization key.audioService).unlockAudio is attached to the "Start" button.