Skip to main content

stopAllSounds

stopAllSounds(): void;

Multiple playback control: Control playback for all sounds simultaneously.


Example

await soundManager.loadSounds([
{ id: 'tokyo-train', url: 'tokyo-train-melody.mp3' },
{ id: 'bells-melody', url: 'bells-melody.mp3' },
{ id: 'techno-tune', url: 'techno-tune.mp3' }
]);

soundManager.play('tokyo-train', { loop: true });
soundManager.play('bells-melody', { loop: true });
soundManager.play('techno-tune', { loop: true });

// Stop all sounds at once
soundManager.stopAllSounds();
Tokyo Trainstopped
Bells Melodystopped
Techno Tunestopped
Try it: Click "Play All" to hear all three sounds together. Use Pause/Resume/Stop to control them simultaneously.