The things I've forgotten

Was going to add sound effects (Wav files) to a game I'd developing. Unfortunately I can't get them to work. I had notes on how to do this but I can't find them either.

So here's what I've got, with the wave file in the same folder as this squiffy file.


sound test

<audio src="button_toilet.wav" autoplay />

Is there something I need to initialize to make this work?

Weirdly, it will not work in the first section called by default (the top). But move it down one and it works just fine. Hmmmm...

I usually do well with Java script instead. It’s less to type and gives me more control. I used it in my first real text adventure, In Cold Blood. I was able to change the volume and stuff sups the dups easily as well as many other variables with it.

Yeah, I've got places I had to change it in Javascript (because it was a full JS section). It wasn't too tough to get working.

This topic is now closed. Topics are closed after 60 days of inactivity.