ActionScript 2.0 :: Disable StopAllSounds Function?
Nov 23, 2009
i have a music player in my shell that plays background music. In swf files that are embeded (two layers in) I have videos playing.i want to make a button that stops the background music. Its too hard to communicate with the music player which is many layers away so i think i should use stopAllSounds.However, after i press it, it also disables the videos. how do i disable the stop sounds function, so that I can play videos, without turning the background music back on?
View 1 Replies
Similar Posts:
Nov 21, 2008
How can I resume sound after after i apply stopAllSounds function?
View 3 Replies
Oct 13, 2002
Dynamically loading mp3's. I have 10 buttons, 1 stop and the others track 01 - 09, these are all in one .swf file. The buttons are all on one layer, on another I have defined all my sounds like so :
firstSound = new Sound();
firstSound.loadSound("track 01.mp3");
through to
ninthSound = new Sound();
ninthSound.loadSound("track 09.mp3");
Then I have the actions for my buttons
on (press) {
//Track 01 Button
stopAllSounds();
[Code] .....
I have uploaded the 9 mp3's, the swf & html file to same folder and this is what happens: [URL]. When any of the 9 track buttons are pressed 7 of the nine mp3's download all at the same time from pressing 1 single button (no track 3 or 9 which play fine normally and have definitely been uploaded) and none of the sounds work. But, when I refresh the page the 7 mp3's that were downloaded now work. The stop all sounds still work on buttons 3 & 9.
View 7 Replies
Sep 13, 2009
I'm doing a basic site with frame labels on the main timeline whose name corresponds to the btn names. A simple otoAndPlay(evt.target.name); I have a basic navigation setup of 7 mcs with mouse eventlisteners for CLICK, ROLL_OVER and ROLL_OUT.
Example:
prepare.addEventListener(MouseEvent.CLICK, navigate);plans.addEventListener(MouseEvent.CLICK, navigate);retire.addEventListener(MouseEvent.CLICK,
[Code]....
Does anyone know a better way to do this so when my mcs are clicked they display the rollover content/art? In essence I'm trying to achieve that when the user clicks a btn it goes to that "page" and the corresponding btn stays highlighted. Pretty standard web navigation technique but I just don't know what the best way to do this in flash is and with how my site is setup.
View 1 Replies
Sep 14, 2011
hi,is there disable ctrl+c function? and cutomize this for own function
View 4 Replies
Apr 4, 2010
I would like to keep the video sound from continuing after I go to the next frame in this file. Should I use "StopAllSounds" and if so where do i put it in the code?here is the code:
// Button ListenersnextBtn.addEventListener(MouseEvent.CLICK, nextSection);prevBtn.addEventListener(MouseEvent.CLICK, prevSection);
////////////////////////////////////////////////////////////////////// /////function
[code].....
View 8 Replies
May 28, 2008
Is there a way to use the stopallsounds command with an exception? I want to stop all narrations (in a presentation) when a button is clicked but keep the background music going. So i want to stopallsounds except the background sound.
View 9 Replies
Jul 10, 2009
I have rather large project that contains several swfs flvs with audio. The project is published in Captivate (which renders a main swf file). After the preloader screen, a lot of the audio files start playing at once at the beginning of the presentation. I have tried inserting an swf with AS2.0 command "stopAllSounds". It works as intended and stops all the cacophony. But then, none of my audio plays throughout the 7 minute project. Does anyone know how I can restart the audio?
View 1 Replies
Apr 3, 2007
I have created a game where all the main actionscript takes place in one frame.For extra functionality I was going to add a button to toggle on/off sounds, after searching this forums and others Im left confused how to implement this.If i choose to use stopAllSounds() Im aware it only stops the current sounds and will not interfere with sounds about to occur.
Collision detection and random sounds occur within my game on an interval, is there a simple way to turn off all sounds permenantly? The only other id would be a button with a toggle and use multiple IF statements to check status of sound on/off.
View 1 Replies
Mar 11, 2009
I am using stopAllSounds(); to stop all background sounds when i enter specific frame in my main movie and it works fine but how do i get sounds to continue to play when i exit this specific frame?
View 1 Replies
Aug 23, 2009
I'm building a dynamic gallery that supports SWFs for individual slides. In order to prevent background sound from carrying over from a previous slide to a different category page, I have attached stopAllSounds(); to navigation menu buttons. It does its job, but it turns off the sounds abruptly. I'm using alphaTo for transition effect from one page to another, and I'm wondering if there is a command that stops playing all sounds in gradation, so that I can make it consistent with page transition.
View 5 Replies
Aug 7, 2006
I have an external SWF file and when I click on a "skip intro" button, right now I have a StopAllSounds(); on an onclick, so it stops the sound of the external swf, is there a way to fade out the sound instead on an onclick of an embeded sound on an external swf?
View 1 Replies
Aug 6, 2009
I've got a project that consists of a main SWF that pulls external SWFS via an XML document. Within the main SWF are the navigation controls (i.e. next button and back button). When the next button is pressed, it pulls up the 'next' external SWF called in the XML file. When the back button is pressed, it pulls up the 'previous' external SWF called in the XML file.
The external SWF pages contain different interactions (i.e. drag and drop, multiple choice exercises, etc). Is it possible to disable the next button until the user completes these exercises?
If the navigation buttons were contained within the individual external SWFS, I know how I could make this work, but the XML setup has me confused. My only thought is using the Timer class, but that doesn't ensure the interaction is complete; rather, it just means the next button won't work for x amount of time.
View 3 Replies
Mar 15, 2010
I have a button that when you roll over it a big window pops up, but then when you click on it, it pops the window up again, now its not a problem but i would like to know if i can disable the click function somehow. so that only the roll over works.
I know you can probably use a movie clip and just tell it with actionscript to load when rolled over, but i don't know how
View 2 Replies
Dec 21, 2010
I am currently have this script on frame 5, AS3:
var timer:Timer = new Timer (2000,45);
timer.addEventListener(TimerEvent.TIMER, timerFunction);
timer.start();
[code].....
View 3 Replies
Sep 23, 2009
[code]How come I cant disable the button by this function?
View 1 Replies
Sep 3, 2011
I have two functions, I need one that of them at the start would be disabled and after decent amount of time or when x = 1000, function would be enabled and become active. How can I do that?
View 1 Replies
Oct 13, 2010
I have a movie clip and i and coding here[code]...
is there any way i can make this type of function ,like true on and off ? i dont wanted to use removeEventListener
some kind like Move="true" pX=20 if Move="false" pX=0
View 4 Replies
Feb 16, 2005
I have a small client that needs to put information into Flash and prevent people from printing the document out on their printers.
Of course, you can always print anything you see on your monitor (Print Screen and other apps), but I am only concerned with preventing users from printing from 1) any browser and 2) from the Flash contextual menu.
View 3 Replies
May 9, 2006
How I can make it so when the right click is pressed the zoom in/out 100% quality and all that does not show.
View 12 Replies
Sep 2, 2009
I am designing a graph to allow line drawing. After the user draws the line, they will drag words (movieclips) from a menu onto to the graph. I am not able to turn of the line drawing function, so when the words are dragged another line is created. I tried to turn off the line drawing onRollOver of the word with no luck. Here is what I'm doing.
Draw line function:
var isDown:Boolean = false;var xPos1:Number;var yPos1:Number;var xPos2:Number;var yPos2:Number;
_root.onMouseDown = function() {
[Code]....
View 3 Replies
Jan 18, 2010
i have about 40 buttons in one movie clip called showmcall i have a massive movie clip that covers all of the movie clips , i've tried disabling the buttons by disabling the movie clip :
ActionScript Code:
showmcall.enabled = false ;
but that didnt disable the buttons.
View 3 Replies
Feb 11, 2012
In my Timeline there are two keyframes with some complicated functions, but the mistake lays in several lines. In the first one I have:
ActionScript Code:
stop();
var fadein:Tween = new Tween(pictureOne,"alpha",Strong.easeOut,0,1,true);
In the second one I have:
ActionScript Code:
stop();
button.addEventListener(MouseEvent.CLICK, goBack);
function goBack(e:MouseEvent):void {
gotoAndStop(1);
}
The point is to make the Tween from the first frame work only once after opening SWF and to disable it after using te command gotoAndStop(1); from the second frame.
View 1 Replies
Feb 25, 2005
Can we disable the right click function in Flash?
View 5 Replies
Nov 10, 2006
i am working on small project where i find my self stopping at this rateMmm.. this project is dealing with buttons placed in MC name = main.ButtonCon the main i am programing those buttons as if
Code:
_root.main.ButtonC.b5.onRollOver = function() {
this.swapDepths(11);
[code]........
View 3 Replies
Feb 25, 2005
Can we disable the right click function in Flash? How?
View 11 Replies
Nov 21, 2009
I have a combo box in my application. I also have a variable called "Status". I want the combo box to be enabled only when the value of the Status variable is 5 or 6. Otherwise, I should not be able to change the value in the combo box. It should have the previous value only.. I had written a click event to disable the combo box. But even though the combo box is disabled, I get the drop down list of the combo box, and If I select some othe value in the drop down,it changes..Only after that it gets disabled.
[Code]...
View 3 Replies
Apr 3, 2011
In my AIR application in Flex 4, I use mx:HTML, and when I navigate to a location like this ut, some websites have "alert" function in javascript like this :lert('hello world!');nd AIR show the message in a box...I just want to remove, or ignore these messages, but I don't know how...
View 1 Replies
Apr 20, 2011
While a user is in a frame, I have the user press F1 to gotoAndPlay another frame, press F3 to gotoAndPlay another frame, etc. But when the user presses the F1 or F3 function key, they get the IE browser search screen or IE keyboard shortcut. How do I use AS3 to have the action taken when the user presses F1 perform the function within my flash file and not the IE process for the function key?
View 0 Replies
Oct 23, 2004
I have a button that I would like to enable and disable a function within my game. The button is called "flashBang". I'm thinking this may need to be done with global variables to make the switch do this procedure. How would I go about scripting this variable? Also I want to be able to target this function during gameplay, if this function is enabled do this line of code - _root.gotoAndPlay("flash");
The code needs to fit somewhere in here i guess.
//hitTest top + bottom wall
if (_root.ball.hitTest(_root.topwall) or _root.ball.hitTest(
_root.bottomwall)) {
_root.yspeed = -_root.yspeed;
_root.audio.gotoAndPlay("flash_bang");
View 3 Replies