Sound And Actionscript - Adobe 38039336 - Flash CS3 Professional User Manual

User guide
Hide thumbs Also See for 38039336 - Flash CS3 Professional:
Table of Contents

Advertisement

• When exporting QuickTime movies, use as many sounds and channels as you want without worrying about file
size. The sounds are combined into a single sound track when you export as a QuickTime file. The number of
sounds you use has no effect on the final file size.

Sound and ActionScript

Control sounds using behaviors
Using sound behaviors, prewritten ActionScript 2.0, you can add sounds to your document and control sound
playback. Adding a sound using these behaviors creates an instance of the sound, which is then used to control the
sound.
Note: ActionScript 3.0 and Flash Lite 1.x and Flash Lite 2.x do not support behaviors.
Load a sound to a file using a behavior
Select the object, such as a button, that you want to use to trigger the behavior.
1
In the Behaviors panel (Window > Behaviors), click the Add (+) button and select Sound > Load Sound from
2
Library or Sound > Load Streaming mp3 File.
In the Load Sound dialog box, enter the linkage identifier for a sound from the Library, or the sound location for
3
a streaming mp3 file. Next, enter a name for this instance of the sound, and click OK.
In the Behaviors panel under event, click On Release (the default event), and select a mouse event from the menu.
4
If you want to use the
OnRelease
Play or stop sounds using a behavior
Select the object, such as a button, that you want to use to trigger the behavior.
1
In the Behaviors panel (Window > Behaviors), click the Add (+) button.
2
Select Sound > Play Sound, Sound > Stop Sound, or Sound > Stop All Sounds.
3
4
In the dialog box that appears, do one of the following:
• Enter the linkage identifier and the instance name of the sound you want to play or stop, and click OK.
• Click OK to verify that you want to stop all sounds.
In the Behaviors panel under Event, click On Release (the default event) and select a mouse event from the menu.
5
If you want to use the
OnRelease
Control sounds with the ActionScript 2.0 Sound object
Use the Sound object in ActionScript 2.0 to add sounds to a document and to control sound objects in a document,
including adjusting the volume or the right and left balance while a sound plays. For more information, see Creating
sound controls in Learning ActionScript 2.0 in Adobe Flash.
Select the sound in the Library panel.
1
Select Linkage from the Panel menu in the upper-right corner of the panel, or right-click (Windows) or Control-
2
click (Macintosh) the sound name in the Library panel and select Linkage from the context menu.
Under Linkage in the Linkage Properties dialog box, select Export for ActionScript.
3
4
Enter an identifier string in the box, and click OK.
event, do not change the option.
event, do not change the option.
FLASH CS3
299
User Guide

Advertisement

Table of Contents
loading

This manual is also suitable for:

Flash cs3 professional

Table of Contents