logo
g Text Version
Beauty & Self
Books & Music
Career
Computers
Education
Family
Food & Wine
Health & Fitness
Hobbies & Crafts
Home & Garden
Money
News & Politics
Relationships
Religion & Spirituality
Sports
Travel & Culture
TV & Movies

dailyclick
Bored? Games!
Nutrition
Postcards
Take a Quiz
Rate My Photo

new
Action Movies
Bible Basics
Houseplants
Romance Movies
Creativity
Family Travel
Southwest USA


dailyclick
All times in EST

Full Schedule
g
g Flash and Animation Site

BellaOnline's Flash and Animation Editor

g

Using Sound in Flash iOS Storybook App


In this tutorial, we will add some ActionScript that will tell Flash CS5.5 to play a sound file when the reader clicks on one of the Christmas ornaments. We have the option of using the same sound file for all three ornaments or "attaching" a different sound file to each ornament. As always, this decision will depend on all the other elements added to your app and the final file size.

We already have the ornaments on the stage and they are animated to sway. This animation is a Tween that plays inside each ornament movie clip. Because we have added the ornament movie clips to Frame 1 of the Timeline, the animation will start when the app loads and will continue until we remove the ornament movie clips from the stage.

We also want our readers to be able to click on the ornaments and play a jingle sound file. Although the ornaments are movie clips and not buttons, we will use ActionScript to tell Flash that our movie clips will also function as buttons.

Although Flash accepts several sound file formats, it's best to covert the file to mp3 format for mobile apps. Once you have the file in mp3 format, you are ready to import it into your project.

Open the storybook project file.

    1. From the menu, click File - Import - Import to Library and choose the sound file.

    In the Library Panel you will find the imported sound file. We will be controlling the sound file with ActionScript. In order to do this we need to make a change to the file by linking it to a class.

    2. Right-click on the sound file and choose Properties. In the Sound Properties dialog box, click the ActionScript tab. Check the box next to Export to ActionScript.

    3. You will notice that the name of the sound file appears in the Class text box. Remove the file extension .mp3. This sound file now has a Class linked to it with the same name.

It is standard to place all the ActionScript on its own layer in the Timeline. Just as we have a layer for the red ornament, we will have an actions layer.

Next →


|
Join us in the Digital Art and Design forum. | Join us in the Flash forum.


Add Using+Sound+in+Flash+iOS+Storybook+App to Twitter Add Using+Sound+in+Flash+iOS+Storybook+App to Facebook Add Using+Sound+in+Flash+iOS+Storybook+App to MySpace Add Using+Sound+in+Flash+iOS+Storybook+App to Del.icio.us Digg Using+Sound+in+Flash+iOS+Storybook+App Add Using+Sound+in+Flash+iOS+Storybook+App to Yahoo My Web Add Using+Sound+in+Flash+iOS+Storybook+App to Google Bookmarks Add Using+Sound+in+Flash+iOS+Storybook+App to Stumbleupon Add Using+Sound+in+Flash+iOS+Storybook+App to Reddit



 



RSS | Related Articles | Editor's Picks Articles | Top Ten Articles | Previous Features | Site Map


For FREE email updates, subscribe to the Flash and Animation Newsletter


Past Issues


print
Printer Friendly
bookmark
Bookmark
tell friend
Tell a Friend
forum
Forum
email
Email Editor


Content copyright © 2014 by Diane Cipollo. All rights reserved.
This content was written by Diane Cipollo. If you wish to use this content in any manner, you need written permission. Contact Diane Cipollo for details.

g


g features
Particle System - Emitter Shape Parameters

Motion Particle Systems - Introduction

Particle Fog in Motion 5 - Scene Graphics

Archives | Site Map

forum
Forum
email
Contact

Past Issues
memberscenter


vote
Poetry
Daily
Weekly
Monthly
Less than Monthly



BellaOnline on Facebook
g


| About BellaOnline | Privacy Policy | Advertising | Become an Editor |
Website copyright © 2014 Minerva WebWorks LLC. All rights reserved.


BellaOnline Editor