Lets hear it! - Adding Ambient Sound
Even so, once your visuals are together, why stick with the silence, when Atmo does great sound? Your world's realism, info quotient and plain fun (yours even) can be easily elevated by sound. Here's how to add some.
Adding a soundscape to your project is pretty easy. Start by deciding what ambient (meaning background, omnidirectional. omnipresent) sound file you will load and play, along with your world load. Sound effects (fx), like wind, water, birds, or machinery, go down smoother than music, 'cause tastes in music are all over the darn dial - which is but one reason why sounds always need an "Off" switch in Controls (yours even).
Next, locate a cool sound file from one of the free web sources - time for a Google search. Swat down all the popups and scumware and download that puppy. You'd best audition a whole crowd of candidates online, before you download, 'cause finding that perfect performer will make a huge difference in how much you like your world. If you have too, bite the bullet and pay for a sound file (easy there, starving artist, this hurts me more than you). What's five bucks, compared to your work-of-art, right?
Now add this code snippet into your world's Atmo JavaScript file (if you don't have one yet, just drop an anchor in your world, paste this code into NotePad, name it "sound.js" and add that name to your anchor's "JavaScript URL:" field. Of course you're going to put the sound file and script in the same folder as your world and all it's parts, right?)
====== Cut below here =========
// --START AMBIENT SOUND SCRIPT --
//---------------------------------------------------
mySound1 = Sound('soundfile.mp3'); //Change "soundfile.mp3" to your .wav or .mp3 file.
mySound1.volume = .5; // Volume range is 0 to 1. Start at half.
mySound1.repeats = 0; // Play forever. "repeats" is right, the API has a typo.
myButton1 = Button ('My Sound - ON ').add (); // Makes a button in Controls.
myButton2 = Button (' My Sound - OFF ').add ();
myButton1.onClick = function (state) { mySound1.play (); } //Sets button action.
myButton2.onClick = function (state) { mySound1.stop (); }
// Start with sound on.
mySound1.play (); // Comment out this line to start with sound off.
// -- AMBIENT VOLUME --
//---------------------------------------------------
mySlider1 = Slider(' Ambient Sound - Volume').add(); //Make a volume control.
mySlider1.range = [0,1]; // Set the range of volumes allowed.
mySlider1.value = 0.5 // Set initial value (same as second line).
mySlider1.onChange = function(val){ mySound1.volume = val; } // Sets slider action.
// -- END AMBIENT SOUND SCRIPT --
======= Cut above here ========
Okay my friend, you are now set for sound.
You say you're allergic to scripts? Well then, just download Fingerstyle's SNDTRIGGER.ZIP. A cool user configurable sound widget from Atmostyle ( http://www.atmostyle.co.uk/ ), - you won't get the controls though. Read the label, take as directed, and soon another non-silent world will grace the galaxy (yours even).
Next time: Local directional sounds or recorded voices which you can have a visitor trigger.
Until then, stay healthy by getting plenty of world building exercise!
