MC Tween: it saves the world.™

Home | Using MC Tween | Documentation | AS2 usage notes | Animation Types | Downloads | Examples | Extensions | Author & Disclaimer | Links

.volumeTo()

Applies To

Sound

Availability

Flash 6 and above, using AS1.

Usage

<Sound>.volumeTo(volume [, seconds, animation type, delay, callback, extra1, extra2]);

Parameters

volume : Desired volume, in percent. Usually from 0 to 100.

All other parameters are standard tween() related. Refer to the .tween() method for reference.

Returns

Nothing.

Description

Shortcut method; does a sound fade on aSound object, going to an specific volume setting. This the tweening equivalent of using Sound.setVolume().

Examples

// Turns off a sound object by fading it out for 0.5 seconds, using a linear transition
<Sound>.volumeTo(0, 0.5, "linear");

See Also

Sound.setVolume()

MC Tween· Zeh Fernando, 2003-2006 · Proudly hosted at DreamHost · Disclaimer