1

Add explination of howler rw

This commit is contained in:
Evan Pratten 2020-04-18 16:16:24 -04:00
parent 1ed27ba07f
commit 2e0df459a5
No known key found for this signature in database
GPG Key ID: 93AC7B3D071356D3
2 changed files with 13 additions and 1 deletions

View File

@ -49,7 +49,19 @@ I also started out by writing a sound system that uses audio channels to separat
- When queueing audio, the 2 most recent requests are always ignored
- Some browsers do not allow me to play multiple audio streams at the same time
Due to these issues, I decided to rewrite the audio backend to use [Howler.js](https://howlerjs.com/). I streamed this rewrite [on Twitch]().
Due to these issues, I decided to rewrite the audio backend to use [Howler.js](https://howlerjs.com/). I streamed this rewrite [on Twitch](). The Howler rewrite was very painless, and made a much nicer interface for playing audio assets.
```js
// The old way
globalSoundContext.playSound(globalSoundContext.channels.bgm, soundAssets.debug_ding);
// The new way
soundAssets.debug_ding.play();
```
This rewrite also added integration with the volume control sliders in the game settings menu (don't mind the spelling mistake):
![Settings menu](/assets/images/settings-screen-ld64.png)

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB