ActionScript 2.0 :: Button Loads Random Sound Clip

Apr 18, 2011

I am a voice over artist and I'd like to have a button and when you click it, it loads one of say 20 mp3s stored...wherever. It can be in the flash movie itself...but I'd rather the script access a directory on my server, that way the movie itself doesn't take long to load.

View 2 Replies


Similar Posts:


ActionScript 2.0 :: Create A Movie Clip That Loops And On Each Loop It Loads A Random Little .jpg Banner From A Directory?

Aug 9, 2004

I am trying to create a movie clip that loops and on each loop it loads a random little .jpg banner from a directory. The banners are named 0.jpg, 1.jpg and so on, a script on the first frame of the loop saying

Code:
_root.randomnumber = random(_root.bannernumber);
_root.bannerloop.bannerholder.loadMovie("http://www.url.com/directory/"+_root.randomnumber+".jpg");

"bannernumber" is a variable from an external text file specifying how many random numbers to cycle through (how many banners), This works just fine and loads up a new banner after each loop cycle. The problem lies in trying to make each banner go to its own url, I have another external text document with variables "click0=url, click1=url etc" where I want the number in each variable to equal the randomnumber variable in flash, then use an on(release){getURL(urlvariable)} function to have it retrieve the url that is somehow in the url variable. Basically, how would I make the urlvariable be equal to the "click0" variable to get the url of the click0 variable into the getURL function? while having the number in the "click0" variable be equal to the randomnum variable?

View 2 Replies

ActionScript 2.0 :: Button Triggers Movie Clip Then When The Tween Finishes Loads Url

Jun 21, 2009

Like the description says. I have six buttons, I want it so when you click any of them the movie clip plays once then when it is finished a specific url loads.

on one of the buttons I have

Code:
on(release)
{
_root.vurl="index.html";

[Code]....

View 1 Replies

IDE :: Fade Out Sound Clip Without A Button?

Jul 31, 2009

I have an animation with some sound attached to it from the library. I want to fade out the sound when the animation ends.. How do I do this? My code for starting the sound is:

var music:Sound = new Sound();
music.attachSound("mySound");
music.start(0, 5);

View 2 Replies

ActionScript 3.0 :: Click On The First Button Loads Ok But When Click On Second Still Showing The First Movie Clip In The Back

Dec 14, 2011

I have read all threads and can not find a solution but i am not somebody with a lots of knowledge about actionscript so here is my problem i am using this script .

[code]....

the problem is that when i click on the first button loads ok but when click on second still showing the first movie clip in the back ,,,,, i have try everything without luck ,,,, i guess i need to keep reading but will like to find an answer to this situation ,

View 3 Replies

ActionScript 2.0 :: Presses A Certain Button A Random Card (movie Clip) Will Appear?

Dec 31, 2009

i'm making a small flash program. whenever the user presses a certain button a random card (movie clip) will appear. i'm sure how to do this, however i think it also involves using a function?

View 7 Replies

ActionScript 2.0 :: Movie Clip Button Sound Over States

Jun 3, 2006

I did a search through the forum and thought I found what I wanted, but in the end couldn't get it to work, so basically all I need is to trigger a sound when the mouse cursor is over the "over" / "out" state. Since I have animations to the buttons, I already have this existing script working fine, just need that extra line of code to add sound to the certain state, but I couldn't think of it off the top of my head:[code]

View 2 Replies

ActionScript 3.0 :: Adding Sound To A Movie Clip Button?

Oct 22, 2008

I'm trying to figure out how to add a sound to a movieclip button so when the user clicks on it a sound is played.

View 10 Replies

ActionScript 2.0 :: Mute Toggle Button To Specific Sound Clip

Jun 3, 2011

Creating the necessary code to make a mute/unmute button in ActionScript 2? I would like the "toggle" button to control a specific sound clip only -- not any other sound within my presentation. Basically I have an intro animation of about 20 seconds that has background music to it. I would like to add a mute toggle button that controls only this music clip and not any other sound found within my presentation. Is this possible? I've seen code for "globally" muting or stopping sounds. I need code for just a specific music clip (sound object?).

View 6 Replies

ActionScript 2.0 :: Random Sound Load And Start Is Speeding Up The Sound?

Dec 16, 2005

I'm trying to load sound dynamically into a clip and then play it randomly. The AS I came up with works great if the sound is embedded and I use the .attachSound() method instead of loadSound(). Now, when I load it dynamically and use the code below, the sound plays very fast and at a higher pitch.

Code:
var crows = new Sound(this);
crows.loadSound("Raven.mp3", false);
crows.setVolume(100);

[Code].....

View 1 Replies

Actionscript 2.0 :: XML Slideshow Loads Random For Some Reason

Mar 18, 2010

Testing locally works fine but as soon as its on a server - published live - the images load random. It loads fine when you publish in flash.

Here is the code and below is the file she sent me.

Code: Select allthis._lockroot = true;
import mx.transitions.Tween;
import mx.transitions.easing.*;
var myShowXML = new XML();

[Code]......

View 1 Replies

ActionScript 3.0 :: Loader Loads Random Image?

Aug 1, 2010

Is it possible to get a loader to load and display a random image?My background images are quite large so I would prefer to use a loader to keep the file size down but I'm struggling to work out how to randomise the images.

View 2 Replies

ActionScript 2.0 :: When The Movie Loads, It Takes You To A Random Scene?

Jan 3, 2003

When the movie loads, it takes you to a random scene. How?

View 3 Replies

ActionScript 3.0 :: Make Sound Not Play When Swf Loads?

Nov 8, 2011

I have a sound in the library named RolloverSound and a MovieClip on the stage with instance name of btn. I hear this sound whenever I rollover btn and that's all I want it to do. The problem is is that it also sounds off when the swf loads and I don't want that.

[Code]...

View 6 Replies

ActionScript 3.0 :: Make Preloader Run Before Sound Loads?

Aug 13, 2009

I am working on a Flash site with background music whose file takes up about 80% of the loading process. The preloader is on the maintimeline.

I've set assets to load on the 2nd frame, and unchecked the "load on 1st frame" box in the music files library properties. Then I get the following message[code]...

View 2 Replies

Actionscript 3.0 :: Loads And Displays A Random Photograph Each Time Someone Visits It

Jun 1, 2009

I'm trying to make a website which loads and displays a random photograph each time someone visits it. I already know how to preload a photo but in this case the photos are quite big, so I want to preload the RANDOM photo with the site at the beginning of the site loading process. A very simplistic approach is to make 20 or something versions of the site, each with a different photo but this would be very, er... simplistic. I usually have a site.swf, a preloader.swf which loads the site, and I use no frames in my site.swf.

View 7 Replies

ActionScript 1/2 :: Preloader Sound Settings Affect The Swf It Loads?

Jun 6, 2011

my preloader music now fades out as the progress bar completes (the preloader code is below with the new code in bold). However, the new code added to the preloader seems to be affecting the sound in the main swf (the bigger swf that the preloader loads - 'lesson.swf' - which is a series of exercises).

The exercises in the main swf have sound cues for right and wrong answers. The first time the main swf loads, there is no sound at all in the exercises. If I navigate to another page of the website and come back to the exercises, the sound is normal. But if I navigate to another page and come back a third time, the sound is audible, but reduced in volume. If I keep switching off the page and back to the page, the sound varies from no sound to full sound to about half the full volume.

Is it possible that the code on frame 2 of the preloader, the code that sets the volume for the preloader music, is also applying to the main swf, so that whatever point the preloader progress bar gets to before the main swf loads becomes the volume of the main swf? The first time the preloader runs, the progress bar goes all the way from left to right and the sound volume fades to zero. Then the volume in the main swf is zero. The next time the preloader runs, it only gets a little way across before the exercises come up, and the sound in the exercises is full volume. Is there a way to fix this? I should add that if I comment out the new code that fades out the preloader music, all the sound works normally.

[Code]....

View 3 Replies

Flash :: File Loads Much Before Than Its Background Sound In Website?

Sep 20, 2011

I have a website at [URL] The problem i'm facing is that after the preloader is done the homepage comes but the other menus still takes much time to load and the sound also take atleast 5 min ! :(

How can i make them all bind together so that after the preloader everything comes together at an instant completely !

View 1 Replies

ActionScript 2.0 :: FMX - Flash Movie Load To A Random Keyframe In A Timeline When The Page Loads

Dec 6, 2004

i think i may have a challenge for you. I would like to have a flash movie load to a random keyframe in a timeline when the page loads. Basically, i'd like to set up a timeline with say 10 movies. When the page loads, i'd like the flash to randomly select from some predetermined keyframes (obviously where each movie starts) and when that movie ends, jump to another section of the timeline. This way, the loading of the movies is somewhat seamless and it looks like i've made 10 different flash movies.

Even if it's not possible to all load from the same timeline, i'd like to have it play the first movie, then when it reaches an ending frame, it loads another random movie from a directory on the server, and then keeps going and going until it can't stand it anymore.

View 4 Replies

ActionScript 1/2 :: LocalConnection - Generate A Random Number In A Dynamic Text Box And Loads An Image As The Background

Mar 27, 2011

I've got two files A and B. A generates a random number in a dynamic text box and loads an image as the background:

[Code]...

I'm trying to avoid useing a button to send the number from A to B, and instead am trying to use an event listener that sends the number when A loads background.jpg; but the number never gets sent (I start with B open already, and then open A). I've gotten this to work with an onRelease event for a button , so i know the LocalConnection coding works, but as I said I want to avoid using a button to send the number. I'm sure it's right in front of me but i've got no clue why it isn't working, so I defer to wiser minds.

View 3 Replies

Loads The Clip Outside Of Those Boundaries?

Apr 14, 2009

i am looking to make something like this for my page.[URL].. i can do all the vid work etc.. the thing im stumped on is how can they resize the working area it uses eg.. where the presenter comes up.. because to start with the swf looks like its only tiny little play start stop thing then it loads the clip outside of those boundaries?

View 1 Replies

IDE :: CSS Not Loads If The Clip Have Only One Frame?

Jan 14, 2010

im working on a banner which have all data included from external text file and styled with css.the code of the banner you can see here:http:[url]....the issue it that my main timeline have 2 frames and the file loops. In this case all works fine , but the on every loop the actionscript loads all the Loaders and data again and again and this cause increasing memory usage (about 1 MB per 2/3 loops) .To fix this I've put a stop(); in the first frame , which fixed the memory leak issue, but now the CSS doesn't load at all - I don't know why. Also I've released that the CSS not loads if the clip have only one frame.

Code:
//Load text from external file
var myTextLoader:URLLoader = new URLLoader();
myTextLoader.dataFormat=URLLoaderDataFormat.VARIABLES;[code].....

View 1 Replies

ActionScript 2.0 :: Load A Random Movie Clip From The Library To An Empty Clip On The Stage Called (bg_graphics)?

Oct 20, 2004

I want to load a random movie clip from the library to an empty clip on the stage called (bg_graphics). the clips in the library are called (green, blue, yellow).

View 5 Replies

Play A Movie Clip While It Loads?

Sep 29, 2010

I want to create a preloader, but I don't want to deal with percentages and loading bars... I just want to play a movie clip while it loads.

View 1 Replies

Professional :: Button Over Sound Plays Again Before Button Down Sound

Apr 15, 2010

I've assigned a sound to the button over frame and a different one to the button down frame. When i over over the button the button over sound plays. When I then click the button, the button over sound plays AND the the sound I put in the button down frame plays.

View 8 Replies

ActionScript 1/2 :: Load A Menu Bar As Movie Clip Loads?

Apr 5, 2009

I have a horizontal menu bar across the bottom of a site I manage, and I would like to load it as the Moive content loads. I have made the menu bar into it's own movie clip, but I cannot work out the code to relate the Menu bar movieclip to the parent movie clip.[url]...

View 9 Replies

Randomly Load Movie Clip When Page Loads?

Mar 29, 2009

I am trying to make what I thought would be a very simple random picture display. I have five movie clips named myClip1, myClip2, etc. All are on the first frame of the timeline. Each has this as a movie clip action:

Code:

onClipEvent(load){
_alpha = 0;
}

The frame also has an action like this:

Code:

nClipMax = 5;
// nClipMax being the number of movie clips
this["myClip" + Math.ceil(Math.random()*nClipMax)]._alpha = 100;

When I test this the background (an image) displays but nothing else, the movie clips stay transparent. I have tried several variations without any luck.I am mainly an asp and net developer that uses flash periodically so be gentle.

View 1 Replies

Actionscript 3 :: A Custom Clip To Run While Flex Application Loads Itself

Jul 15, 2010

Whenever a swf is loaded a custom movie is shown (by default a rotating circle), is there some way where I can have my custom movie to play there.

View 1 Replies

ActionScript 1/2 :: Make Button On Rollover Starts Sound And Rolloff Stops Sound?

Jul 28, 2009

I have several buttons in a movie and I want to be able to rollover an individual button and play the sound for that button and when I rolloff I want the sound for that button to stop.

View 6 Replies

ActionScript 2.0 :: Add Mute Sound And Unmute Sound Script In A Single Button?

Sep 21, 2011

how to add mute sound and unmute sound script in a single button?

View 2 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved