• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

excaliburjs / Excalibur / 17003581534
89%

Build:
DEFAULT BRANCH: main
Ran 16 Aug 2025 03:12AM UTC
Jobs 1
Files 238
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

16 Aug 2025 03:07AM UTC coverage: 87.367% (-0.4%) from 87.801%
17003581534

push

github

web-flow
feat: Add SoundManager for managing music/fx/audio in a friendly way (#3472)

Closes #590
Related #1161 

## Changes:

- Added a new `ex.Sound({...})` option back constructor to set all the props you could set on sound at constructor time
- Added new `ex.SoundManager({...}` api to manage volume and muting on large groups of sounds at once

```typescript
var soundManager = new ex.SoundManger({
  channels: ['fx', 'music', 'background'],
  sounds: {
    jumpSnd: { sound: jumpSnd, volume: 0.4, channels: ['fx'] },
    forestSnd: { sound: forestSnd, volume: 0.2, channels: ['music', 'background'] },
    challengeMusic: { sound: challengeMusic, volume: 0.2, channels: ['music'] },
    guitarLoop: { sound: guitarLoop, volume: 0.2, channels: ['music'] }
  }
});

toggleMusic.on('pointerdown', () => {
  soundManager.channel.toggle('music');
});
game.add(toggleMusic);

game.input.keyboard.on('press', (evt) => {
  if (evt.key === ex.Keys.J) {
    soundManager.play('jumpSnd');
  }

  if (evt.key === ex.Keys.M) {
    soundManager.channel.mute('music');
  }

  if (evt.key === ex.Keys.A) {
    soundManager.mute();
  }

  if (evt.key === ex.Keys.S) {
    soundManager.unmute();
  }

  if (evt.key === ex.Keys.U) {
    soundManager.channel.unmute('music');
  }

  if (evt.key === ex.Keys.P) {
    soundManager.channel.play('music');
  }

  if (evt.key === ex.Keys.V) {
    soundManager.channel.setVolume('music', 0.9);
  }
});


```

5172 of 7237 branches covered (71.47%)

89 of 189 new or added lines in 3 files covered. (47.09%)

14018 of 16045 relevant lines covered (87.37%)

24499.56 hits per line

New Missed Lines in Diff

Lines Coverage ∆ File
1
68.75
0.0% src/engine/Util/IFrame.ts
4
89.12
3.29% src/engine/Resources/Sound/Sound.ts
95
44.12
src/engine/Resources/Sound/SoundManager.ts
Jobs
ID Job ID Ran Files Coverage
1 17003581534.1 16 Aug 2025 03:12AM UTC 238
87.37
GitHub Action Run
Source Files on build 17003581534
  • Tree
  • List 238
  • Changed 2
  • Source Changed 2
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #17003581534
  • 82b52446 on github
  • Prev Build on main (#17003507996)
  • Next Build on main (#17003768221)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc