ActionScript 2.0 :: Add Audio That Will Play When User Moves Over Buttons?
Feb 5, 2006
I have a presentation which is split into several different movies which are linked together by buttons, all I am trying to do is add a sound which will play when the user moves over the button, and then another that will play when they click on the button; I got this to work once but it cut off the sound because it loaded a new movie, so I found the onSoundComplete command, which I've tried in a load of different ways but nothing works...
here's the code i've got at the moment:
on (rollOver) {
mySound = new Sound(this);
mySound.attachSound("twisted1");
mySound.start(0, 0);
} on (release) {
mySound = new Sound(this);
mySound.attachSound("twisted2");
mySound.start(0, 0);
twisted2.onSoundComplete = function(loadMovie("history.swf", "this"));
}
And this is the error that I am getting:
**Error** Scene=home, layer=links, frame=1:Line 12: ')' or ',' expected twisted2.onSoundComplete = function(loadMovie("history.swf", "this"));
I've tried a few things but i just seem to get more errors...
View 6 Replies
Similar Posts:
Feb 21, 2010
I'm trying to make an application in cs4 that allows the user to move a stickman into various positions and then play back the sequence of moves. Despite the fact that I haven't even gotten that far yet I also would need an undo and redo button. I have a few ideas regarding this i.e. logging each body part's coordinates as the user moves them and editing the timeline through some sort of 'record' button and undoing by having some sort of array...none of which I know how to implement into actionscript yet.
View 1 Replies
Apr 21, 2010
I have MC masked with TEXT,when the user moves his mouse down more text appears from the bottom and when he moves it goes bakc to the original position...I do not want the mouse wheel .. I woudl like to do it by mouse hovering...
View 5 Replies
Jun 6, 2009
Is there a way to import audio into Flash and use it in a way similar to a movie clip (give it an instance name and use a button to play it etc.)
View 3 Replies
Apr 16, 2010
I want to do something that is probably very simple, but I'm having difficulty.
I want to create an audio player with play, stop, and pause buttons that I can then import into Fireworks/Dreamweaver.
View 2 Replies
Jun 12, 2010
I am making a simple radio interface and i have 6 preset buttons which i want to have play the specific preset button's song which is in the library and stop/pause the current song when any preset button is pressed.
i tried using the attachSound function, with associated identifiers but not sure if that is the right way to go. It plays the songs, but doesnt stop them.[code]...
View 12 Replies
Jul 8, 2011
I'm struggling with a script to make a simple audio player. I'm loading the audio externally, using loadMovie. I have three buttons on stage ("Stop","Play", and "Pause"). First two work nicely, problem is the third one. here are the actions for the three buttons:
STOP button - Working
ActionScript Code:
on (press) {
audioContainer.unloadMovie(10);
}
[code]....
BTW, the external movie clip contains an audio track inside a movie clip. Any ideas how to make the thrid button to "pause" the audio?
View 8 Replies
Sep 12, 2009
ow to go into frame 2 when the user moves the mouse over some item?
View 1 Replies
Jun 12, 2010
how to make mp3 player made in flash resume music when user moves from one html page to another?
(so that the music is constant it doesn't restart with every page).
View 1 Replies
Jul 2, 2010
For one of my projects I need users to be able to communicate with each other in an audio mode. The thing I'm concerned about is the scalability of the project if it even gets big in terms of bandwidth consumption.
What are the alternatives to passing the audio through my server to the users?Is it possible to create a link between two users so they can exchange their stream of data (audio in this case) so that it doesn't pass through me, while still being able to control the time they've been connected to each other and some other information?
As for now it's just an idea I have in mind but I don't really know what to look into. I think it will probably need to be some plugin dependant solution so that's why I tagged the question like that.
I'm not looking for a concrete solution, just a little push in the right direction from someone who has been through something similar.
View 1 Replies
Jan 21, 2010
I am building a sliding image movie. It takes two photos and compares them by using "startDrag" to slide a "setMask" MC horizontally to reveal one photo under another. The idea here is to compare two photos taken 50 years apart.
[Code]....
As you can see I have two MCs here one is a mask and the other is a handle of sort. They work fine separately but I would like to have the two function in unison or as one MC. The handle MC is just that a handle that appears on the left edge of the masked image. So when user drags the handle the masked image moves as well. (or vice versa)
View 4 Replies
Mar 15, 2009
I am trying to get when a user mouses over the button some content shows up and moves with the mouse until that user moves off the button..does anyone know how i can acheive this...
View 13 Replies
Aug 25, 2009
I have an audio player that has a custom timeline and playhead. I am using a start and stop drag to move in the time line but the only way i can make it work is to have it play when ever I release the play head. I would like it to stay stopped if the player is paused and play if the player was playing.
[Code]...
View 5 Replies
Apr 13, 2011
My server is streaming binary audio data (mostly mp3 files) to a client (a browser). This client stores the audio data in memory.
What I'm looking for is a flash audio player that I can input the binary audio data so that it can play the audio file.
Preferably, the flash client is merely a bridge to Javascript so that I can handle everything in Javascript and simply use Flash's audio features, but this is not a requirement.
View 1 Replies
Sep 20, 2007
i am creating a simple set of a few rectangles stacked on top of eachother (going to be like a stack of postcards) and i want to have the user click on the top rectangle and it moves to reveal the one underneath it. i have it all set up to work except i can't think of a way to stop it from being clickable after it's been moved to the side and the 2nd rectangle is revealed. does this make any sense? here is my code:
[Code]...
View 2 Replies
Apr 13, 2011
I've got an app based on four frames with seperate events on each frame. The app is powered in AS3 and every frame calls stop(); and everything works well but the swf file in flash player has a problem where if the user hits control > play it moves to the next frame.How can I stop this? A simple conditional would prevent it but errors are triggered this way from ongoing functions from a previous frame.
View 3 Replies
Feb 27, 2012
I have created two buttons for separate audio files. Essentially if you click on the button it will play and stop. This works great! I have also injected a SoundMixer.stopAll(); to ensure if you click between both buttons that it will stop the current audio file to play the next one. My problem is when I select the 2nd button for the first time everything seems to be working...it's when I attempt to click on the first button again, that it will require 2 clicks and then it stops and plays accordingly...anyone know how I could eliminate this annoying two click process?
[Code]...
View 1 Replies
Jan 27, 2010
I am trying to work out how to do something really hard and i think the only way that I can do it is to pass a timer an argument. I want to create a class that moves buttons to the right on mouse over, and moves them back on roll out. But I am trying to make a sort of easing effect in action script. The last movement should be 1 pixel, the second to last move 2 pixels, the third to last be 3 pixels etc.
The class will have a variable that stores the original x coordinate and the desired resting coordinate for the button on roll over. on roll over, the script calculates the number of pixels between where it is and the destination, or on roll out, it would calculate the number of pixels from its current position to the original position. Then it would use that number to do the following calculation:
while(numPix>countPix){
count++
countPix+=count
} this.x=destinationX-countPix /*or + count pix depending on weather its moving to the right or left*/
while(count>0) {
this.x+=count /*or -= if moving back*/
count--
/*timer would elapse here*/
}
So u see, it counts the number of pixels it needs to move, then it counts the number of increments (count) it needs to move between timers for this sort of easing motion. I just don't know how to implement this in actionscript
View 1 Replies
Nov 11, 2009
I am trying to remove a dynamic textfield when I click one of 2 buttons which moves to another frame.I can't seem to get it off the screen. removeChild works but it removes it totally and its not there when its suppose to be.
View 4 Replies
Apr 9, 2010
New to AS and would like to know how to make a simple page where the viewer has to click several buttons before it moves on to the next scene. They can only go to the next scene when all of the buttons have been clicked.
View 3 Replies
Sep 11, 2009
looking to create an image/mc slider that moves form right to left via user clicks of a left and right button.I would assume I would create an array to hold a series of mc's in (my images) and then tell the left and right buttons CLICK events to move linearly through the array (displaying next in line and previous etc.
View 1 Replies
Dec 11, 2009
To start things off, I use Flash CS3.moving menu that moves on its own when the mouse moves around it. Like the menu moves up when the mouse moves down.[URL]i have found similar tutorials for what i wanted.. but they are AS2 or older versions of flash..and what i needed is more along the lines of AS3 as that's what my class is learning and using.Does anyone know of an AS3 or anything that works with Flash CS3 tutorial thats what I'm asking?
View 0 Replies
Aug 1, 2010
I'm developing a game, here is a screenshot:I have a function in my main loop called moveShip that moves the player's ship if some buttons are pressed. The trouble is, some commands began to break it recently, such as removeChild(debriefingScreen), and I have no idea why. Also, firing (spawning bullet movie clips) restores the moveShip functionality 0_
View 2 Replies
May 27, 2009
I was wondering if it is possible to analyze music playing on a user's computer and show visualizations of it using computerSpectrum? Basically, can Flash read the audio playing on a computer or just the user's microphone?
View 6 Replies
Aug 20, 2010
In my tracking I records the voice, it generates the file (if i download I was able to listen to it), but if I try to play, it doesn´t play. If I use FP9 r124 it works, using FP10r53 or the latest 10.1.82.76 it fails !!! all with the same SWFhas anyone experienced the same? I can not ask everyone to downgrade the flash player.
View 8 Replies
May 8, 2011
This isn't another one of those "How can I record audio in the browser?" questions... I know that the HTML5 Stream API is around the corner and Flash can already access the user's microphone and camera. I'm simply wondering, as a Javascript developer with little knowledge of Flash, if anyone has developed a JS library that hooks into Flash's device capabilities for recording but sends the results back to javascript (presumably using ExternalInterface).
In other words... libraries like SoundManager2 utilize a Flash fallback for audio playback, but they don't seem to allow for recording. Has anyone written a JS library that uses an invisible Flash movie to allow audio recording?
View 2 Replies
Oct 5, 2011
I know how to use AS3 to record sound from the user and enable them to save it to their computer. However, I would really like instead to allow them to either send it to an email address right after recording (without them having to save it to their computer first and find the file), OR to let them save it so that the site owner can access it (They would know that it was happening.).
View 1 Replies
Oct 27, 2009
I'm new to Flash media server family. I need a server that can capture user recorded video/audio (through a flash recorder) and save it as a flv file on the server. which one of those server family is for me? I'm currently doing it using Red5, but would like to try out Flash media server as well.
View 1 Replies
Oct 22, 2010
Is there a way to suppress/mute the video portion of an FLV while it's playing so only the audio comes across? Is there a Flash player out there that does this?
View 3 Replies
Feb 3, 2012
I had been developing one Flex application , in that users are allowed to upload there own swfs . The problem is, my application has a frame Rate of 11 , if the user tries to upload the swf with higher frame and audio with it( ie Framerate of 24 with AudioFLV ). this makes my application to run at the higher frame rate of that same user uploaded swf.
View 1 Replies