Playing Background Music

Tensin
I can't figure out how to get my background music playlist to play. Anyone know how?

This probably has a really simple answer but humor me please.

Thanks!

Silver
Need more info. What have you done to try and play a background sound? Is this online or offline? What file format is the sound? What browser are you using (if your game is online)?

Tensin
The game is on my computer, I'm pretty sure I have the newest version of Quest. I've tried putting the background music (which is an mp3) in by using a function and "add sound".

Silver
mp3 should work fine with the windows Quest editor (which apparently uses chrome as its browser). Be aware that when published only chrome, IE and Safari support mp3 files though.

To play a sound you run a script and choose 'play sound' which then gives you the option to browse your hard drive for the audio file you want. This can all be done in the UI. You can select it to loop or be a one shot. I'm not sure that you're doing the right thing if you're trying to do it using a function. It probably can be done that way - I've never tried - but the simplest method is through running a script when you want the sound to be played.

This is the tutorial on running scripts although I'm sure you already know this.

http://docs.textadventures.co.uk/quest/ ... ripts.html

Tensin
That works for playing a single sound, but I'm trying to play back ground music throughout the entire game.

Silver
Tensin wrote:That works for playing a single sound, but I'm trying to play back ground music throughout the entire game.


In what way? You can loop a sound. So you can be in the lobby and play a sound on loop then move to the lounge and play a different sound on loop etc. sound can mean music or whatever.

If you want to play an entire soundtrack from start to finish regardless of the game state then that's a different question. You would need to create one entire file of the whole soundtrack and play that. Unfortunately I think Quest has file size limits but that should only really apply to the online not offline version.

You're going to have to be more specific in your question as I'm still unsure of what you actually want.

Tensin
Exactly what I'm trying to do is get a sound (a piece of music) to start at the beginning of the game with out needing a prompt. I then want it to play on a loop, but I know how to do that bit.

Getting the music to start with out a prompt is what I'm having the issue with.

george
Can you put it in a game start script? This shows you how to create a script at game start,

http://docs.textadventures.co.uk/quest/ ... ction.html

Silver
Id be aware that Quest probably won't like a big sound file when uploaded. So it'll work offline but not online. I don't know that for a fact but its a hunch based on it acting that way with image files.

Silver
george wrote:Can you put it in a game start script? This shows you how to create a script at game start,

http://docs.textadventures.co.uk/quest/ ... ction.html


This. Just select play sound instead of print message.

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

Support

Forums