WebAudio Reliability Fixer
Key Files
- •
src/utils/AudioManager.js— singleton that wraps Howler.js (v2.2.4) for playback - •
src/utils/audioEngine.js— low-level AudioContext/Tone.js (v15) scheduling - •
src/utils/audioPlaybackUtils.js— start/stop helpers for ambient and gig modes - •
src/hooks/useAudioControl.js— React hook that gates audio on user gesture - •
src/components/PixiStage.jsx— may trigger audio transitions on scene changes
Workflow
- •Verify user-gesture gating in
useAudioControl.js— AudioContext/Tone.js must not start before interaction. - •Check start/stop scheduling in
audioEngine.jsand ensure timers and Transport events are cleared on scene transitions. - •Inspect
AudioManager.jsfor scheduling density — avoid queueing overlapping Howl instances. - •Review scene transitions in
src/scenes/for audio lifecycle gaps (e.g., Gig → PostGig). - •Add minimal debug logging via
src/utils/logger.jsaround context state transitions.
Output
- •Provide the highest-impact fixes first.
- •Reference specific files and line ranges for each fix.
Related Skills
- •
audio-debugger-ambient-vs-gig— for ambient vs gig playback-specific bugs - •
pixi-lifecycle-memory-leak-sentinel— audio leaks often accompany Pixi.js lifecycle issues