Button to play outro before new intro
I am building an animated menu in CS3 using AS 3.0. I have a
menu of four buttons. For simplicity, let's say A_btn,B_btn,C_btn
and D_btn
Now on the timeline I have labels that have intro and outro
animations for each.
Let's say the lables are labled: Ain, Aout, Bin, Bout, Cin,
Cout, Din, Dout
Ok, so I have the buttons all playing the intros just fine.
How do I get them to play the outro before moving on to the
appropriate intro? Note: each intro and outro is completely
different and independant. In other words, I'm not using the same
transition for each one.
Here's a link to a test project file that shows the buttons
playing the intros.
Click
Here to see example
Here's the current AS3:
stop();
function onHomeClick(evt:MouseEvent):void {
gotoAndPlay("Ain");
home_btn.addEventListener(MouseEvent.CLICK, onHomeClick);
function onAboutClick(evt:MouseEvent):void {
gotoAndPlay("Bin");
about_btn.addEventListener(MouseEvent.CLICK, onAboutClick);
function onWorkClick(evt:MouseEvent):void {
gotoAndPlay("Cin");
work_btn.addEventListener(MouseEvent.CLICK, onWorkClick);
function onContactClick(evt:MouseEvent):void {
gotoAndPlay("Din");
contact_btn.addEventListener(MouseEvent.CLICK,
onContactClick);
I tried adding this after stop and before function, but it
doesn't do anything.
var gotoA:Array = new Array();
home_btn.addEventListener(MouseEvent.CLICK,f);
function f(e:MouseEvent){
gotoA.push("Aout");
gotoAndPlay("Bin");
Any help would be appreciated.
Thanks.
Here's the example link:
http://www.jpgproductions.com/Azure/MainMenuBtnTST.html
or
just click here
Similar Messages
-
How to add a button to play 1 minute audio?
I would like to add a button to a web page. Clicking the button would play about one minute of audio. I will appreciate very much if someone could help me accomplish this. Thanks greatly in advance. Tom
As a caution,
1 of the absolute WORST things you can do in web design is to have an audio file autoload and play as soon as a website loads. This is incredibly annoying to most web users.
I am not saying you are planning this, but consider the following situations:
1) A user is listening to an audio broadcast of the local news while surfing the web, or his favorite cd. All of a sudden, what they are trying to listen to is unexpectedly overridden by sounds from a web page, that they didn't ask to hear.
2) A user is planning her wedding, while at work. She logs onto a photography website quickly to view some pictures that a co-worker had said were great, and all of a sudden the people in the next 20 cubicles are distracted by music blaring out.
3) Your aunt finally gets her young, collicky child to sleep. To unwind, she surfs the web for a bit. She decides to pop over and read your blog, and all of a sudden the music breaks the silence, waking up the child.
Audio and video on a webpage is great, but should ALWAYS be at the control of the end user.
Cheers!
Ian -
Rollover buttons that play a movie clip.
Hello,
I am new to Flash and I am trying to accomplish a simulation such as this example, http://www.its-about-time.com/investinesart/coalplantvirtualtour.swf. I have all of my movie clips done, but how do I tell a rollover button to play a specific movie clip? I also want to have all the movie clips to play simultaneously via a rollover button as shown in the example. I've attached a captured image of my timeline, if that helps. I've tried everything so far, but nothing is working! What is the simplest way of doing this?
I have this inside one of the movie clips (mc_2) in a seperate layer under - (actions)
RO_btn.onRollover = function(){
mc_2.play();
On the main timeline I have an actions layer with this:
stop();
Thinking that this may stop all of my movie clips but it doesn't.
Should I make an actions layer in each movie clip with this syntax huh? stop();?
I'm frustrated!!
Thanks, if you can help!
MGHi,
I have made something that you are looking for.
It will be of help to you.
basically you will have to create a few movie clips namely:
2 buttons: (name them a_btn, b_btn, c_btn, d_btn, e_btn)
3 movie clips (I am taking example image1_mc, image2_mc, image3_mc)
in each of these movieclips.place 2 frames and on second frame put your movieclip(one in one).on both the frames put stop()
now click on a_btn and write this script
on (rollOver) {
_root.image1_mc.gotoAndPlay(2);
_root.image2_mc.gotoAndPlay(2);
_root.image3_mc.gotoAndPlay(2);
on (rollOut) {
_root.image1_mc.gotoAndPlay(1);
_root.image2_mc.gotoAndPlay(1);
_root.image3_mc.gotoAndPlay(1);
with this all 3 animations will work simultaneously. if you need to run any one of the movieclips at a time the you can address that mc in particular
.Say if you want only 1 mc to move at a time then put this on btn 2
on (rollOver) {
_root.image1_mc.gotoAndPlay(2);
on (rollOut) {
_root.image1_mc.gotoAndPlay(1);
.Dont forget to give proper instance names to movieclips.(they are in properties panel.)
Cheers! -
How do I include an entire hour-long performance on a DVD and also have menu buttons for playing isolated sections of the performance?
So far, I've already done the individual menu buttons for sections of the performance. How do I set up some kind of "play" button that will play the video of the entire performance straight through? Will this be too much material for the DVD to hold? Does the program recognize and not replicate material to save space? If so, will it interfere with that if I add edits to individual sections that will not be in the video of the entire performance?Hi
If You only need
• Play movie in full
• Start into the movie at specific places e.g. Chapters - then play to movie ends
Then this is fairly simple - Just add Chapters in Your Video-editor (iMovie or FinalCut)
(some quirks to keep in mind - No Chapter mark in any transition or within 2 sec from it - AND - only Lettera A to Z and 0 to 9 - no other letters/symbols at all)
BUT
If You want to
• Play full movie (with or without Chapters)
• Play an individual Chapter then return to Menu
This function is not standard in iDVD - but has to be faked one way or another.
Please read my notes on this and be aware of the 60 minutes / 12 minutes limit in iDVD (THIS is including the Menu and it can take 15 minutes or more from the movie time)
Play all resp one chapter at a time
Play All Button
1. There are NO - Play All - button in any version of iDVD
2. It can be faked in several ways
• Easiest and most fault proof way is to make a doublet movie containing All and with
Chapters set to match. It will take up x2 space but is easy to understand and produce.
Cons: Tried this in iMovie’11 by Exporting out each part as a full Quality QT.mov then Importing back into new events and putting these into a new project (Play All project). Resulting DVD had Audio that was OK (as parts) - BUT the picture was very bad and standing photo were cut of in hight. So the Play All movie has to be created from same material and exactly in the same way as the individual parts + then Chapters has to be set to match.
• It's said that one can put all movies into a Photo/SlideShow and this will also
give the function of a Play All button - Tested - and ONE HAS TO un-cheque - Scale pictures to TV-Safe area else it will be a black frame all around and a small picture !
Cons: BUT - When tested with music videos - the same video on main Menu played nicely with OK Audio. The Play All version in SlideShow had a signifcant Distortion - as on telephone or worse.
Mike Evangelist1
You might be able to get close to what you want by using a slideshow in iDVD. (It's not widely known, but you can put videos in a slideshow.) If you set the slide duration to manual, playback will pause after each movie/slide, and you can continue with the 'next' button.
3. Using another program to do this e.g.. Roxio Toast™ where there is a Play All button option.
Summary
a. Making a Play All movie with same care as the individual Part movies - gives a very Good Result
b. Using Roxio Toast™ - also an usable way to go
Yours Bengt W -
Can someone provide a simple button which plays a sound for ios?
I need a sample fla or the code for a button that plays a sound when touched, adobe air for ios.
I have tried multiple tutorials and nothing seems to go right.
a sample fla would be awesome.
i used to be an actionscript 2 programmer so everything is new to me in actionscript 3.actually i just seen you cant put actionscript for iOS...is that true?
well to develop this for android i have this code.
but when i hit the button nothing plays, yet it plays find on the computer.
import flash.events.MouseEvent;
import flash.media.Sound;
import flash.net.URLRequest;
Multitouch.inputMode=MultitouchInputMode.TOUCH_POINT;
var mySound1:Sound = new Sound();
var mySound2:Sound = new Sound();
var myChannel:SoundChannel = new SoundChannel();
mySound1.load(new URLRequest("myFavSong.mp3"));
mySound2.load(new URLRequest("myFavSong2.mp3"));
mission_btn.addEventListener(TouchEvent.TOUCH_TAP, onClickPlay1);
stop_btn.addEventListener(TouchEvent.TOUCH_TAP, onClickStop);
ntl_btn.addEventListener(TouchEvent.TOUCH_TAP, onClickPlay2);
function onClickPlay1(e:TouchEvent):void{
myChannel.stop();
myChannel = mySound1.play();
function onClickPlay2(e:TouchEvent):void{
myChannel.stop();
myChannel = mySound2.play();
function onClickStop(e:TouchEvent):void{
myChannel.stop(); -
Why not update Tutorials before new Releases?
Why not update the Tutorials before new releases?
As a newcomer to Dreamweaver, downloading the practice files as advised and despite trying to follow the Tutorial for Bayside Beat, each and every step had a completely different Interface, Menu or Cursor Point for what should be a simple step by step guide!
The guide is pointless to anyone downloading the latest version of Dreamweaver to use for the first time in relation to the Tutorial that accompanies it. Despite the answers provided to questions from other members, the differences are not as plain and easy as the responses provided to newcomers of Dreamweaver.I agree that they should have updated the tutorial to match the new updates. But the differences weren't that bad that you couldn't do the tutorial. I was able to figure my way through the tutorial but instead of completing it in 45min. It took me 4hours. I will list some of the differences that I saw in the interface:
- Title box moved down to the bottom of the property inspector
- Live and Design key are one instead of two separate buttons
- There were no expanded or compact view for the CSS design box (if there is one, let me know because I didn't find it)
- Changing the list-style-type property is under Text not Others (This is when you remove the bullets from the navigation bar)
- The tutorial where you have to remove the blue after you floated the two columns, there are no selection for Left, you have to manually input it in. Example: Select Footer, under Other select Clear and the box next to it type in Left.
I found that it was pretty helpful to print off the extended version of this tutorial in text. It goes over more things in depth and cover other design elements that wasn't in the videos. Here's the link: Learn Dreamweaver | Adobe Developer Connection -
How do i actionscript my flash button to play the sound while being transfered to another url?
Hi!
As the title says:
How do i get my flash button to play my sound when i click on
it while being transfered to another url?
I did get it to work, but only when i set the script to
"_BLANK". When i clicked the button then it played the sound and
opened the url in a new window. I want it to be in the same window
and still play the whole sound.
Now i get just 1 or 2 sec then when im transfered, it stops
playing the sound.
I hope this explains it..... if any typo....its because im
Swedish =)
Thanks in advance!If you are jumping to another URL using the same window you
cannot have a sound start on the press of a button and that sound
to continue on.
Reason
You are removing all trace of the sound and the swf that
contains that sound file.
Work arounds
1.Take a look at "frames". This way you are keeping the
container page and opening another page inside of that page.
2. Div's. again you are importing a page into a particular
area yet keeping the swf, with the sound playing, in the parent
frame. -
How to code a button to play and pause sound using load sound?
how to code a button to play and pause sound using load sound?I have used load sound methos to attach the sound.Can anyone help me?
Hey thnx,
I have used this code on sound's button's frame.and my stop n play button is on another screen.main sound button and stop button is on diffrent screen.
Here is my code-
stop();
adaDrut1.onRelease = function () {
mySoundC = new Sound(this);
mySoundC.loadSound("F#/Bhajni1.ark", true);
mySoundC.onSoundComplete = function() {
_root.mySoundC.start(0,999); }
gotoAndPlay("play2");
_global.myTaalLaya = "Low1";
adaDrut1 is a sound button.And there are lot of buttons with diffrent sound.
Thanks.. -
How do i stop ads advertisments before new items start??
is there any program to stop 30 sec ads playing before news or videos play???
Try [https://addons.mozilla.org/en-US/firefox/addon/adblock-plus/ ABP] and [https://addons.mozilla.org/en-US/firefox/addon/noscript/ No Script]
-
Stop random button animations playing
Hi. I'm sure this is a common problem, but can't find any
answers...
I have created a menu structure with buttons that play an
animation on mouseover and stop on mouse out (thus returning to
frame 1). Only problem is, sometimes when the page is loaded an
animation will play without any interaction, also if the mouse is
moved too quick, the mouseout code isn't triggered and the
animation keeps playing.
How do I stop this from happening? Thank you.Change it to start on click and stop on click on a different
button.
Or, create a movieClip with a button1 on frame one and a
different button2
on frame 2.
When the user clicks button1, gotoAndStop frame 2.
When a user clicks button2, gotoAndStop frame 1.
On frame 1 put the code:
myAnimation.play(); //the instance name of your animation
On frame 2 put the code;
myAnimation.stop();
Dan Mode
*THE online Radio*
http://www.tornadostream.com
*Must Read*
http://www.smithmediafusion.com/blog
*Flash Helps*
http://www.smithmediafusion.com/blog/?cat=11
"flanky" <[email protected]> wrote in
message
news:e9erlp$drh$[email protected]..
>
> Hi. I'm sure this is a common problem, but can't find
any answers...
>
> I have created a menu structure with buttons that play
an animation on
> mouseover and stop on mouse out (thus returning to frame
1). Only problem
> is,
> sometimes when the page is loaded an animation will play
without any
> interaction, also if the mouse is moved too quick, the
mouseout code isn't
> triggered and the animation keeps playing.
>
> How do I stop this from happening? Thank you.
> -
What codec do I need to add to play a video that is called .avi
It will not play on my new Macbook Pro since I put it into the movies section of my launchpad. When it was on the desktop It worked fine. I moved it back to the desktop and it still does not work.
The error message says The document " .avi" could not be opened.
A required codec is not available.Download VLC Media Player which plays anything you throw at it and Perian (AVI and FLV support).
-
Hi guys, hope u can help me, i bought a movie from itunes a few months ago, and i´ve played it before in my laptop (Toshiba Satellite L755D) with windows 7 home premium, i have my Bill in my e-mail, but when i try to play it now, it won´t! a message comes back with a legend saying something like this: "To play avengers hd you must have an integrated screen that allows hdcp" but i´ve played it before tons of times!!! whats wrong..? and when i go to the store and point an error on the selected item (avengers hd) it says that my search has no results!!! please help me :-( is not fair that i spend almost 20$ for something that it´s just not working anymore!!!
Movies are not always available for redownload. Is there a reason why you deleted it instead of simply transferring the purchase to the computer and then removing it from the iDevice?
-
No "before new record saved" trigger event in workflow definition ?
Hello,
I have following problem: I have to make a simple integration, where products have information about available quantity of given product . Assume we have field - it is called "Available amount" and it tells how many products are on stock. Now suppose we have created an opportunity, and we want to add Opportunity Product Revenue - we're selecting product and then quantity. I want to make OCOD to display message and prevent from adding opportunity product revenue, when its quantity is greater than "Available amount" field which is present in associated product record. I've created small C# application and used workflows to create Integration events. It works - but not exaclty how I want it - when I add a new record the workflow generates integration event - but I'd like to generate integration event before a record is created, also I'd like to show a notification from OCOD. But for "revenue" we do not have a trigger event called for example : "before new record saved" - we have only "when new record saved" and "before modified record saved".Hi,
From your requirement, it seems you, want some kind of check. Did you try puting this validation on field level, i guess you would need to join fields and compare in field validation. So, whenever user creates a new record this validation kicks and user is notified of the error. -
Web Viewer - getting buttons to open in a new tab or window
I am trying to get a button to open in a new tab or window in the DPS web viewer.
The options when creating a button are:
Open link in folio
Open link in device browser
Both which do not work when we export the web viewer.
I know it is possible as Adobe are using this function for their Inspire magazine. This does not seem to be html either that they are using. See link here - at the bottom of the page: Adobe Inspire Magazine October 2014: The Truth in a Face
Any help with this issue would be highly appreciated.There is a parameter on creating the iFrame called externalLinksOpen. They can set it to 'window', as it defaults to inline, which opens it in the current window. It's documented here:
http://www.adobe.com/devnet-docs/digitalpublishingsuite/ContentViewerForWebSDK-2.0/classes /FrameService.html#method_createFrame
There is also a demo linked from our 'What's New' section under 'External Link for Embedded Viewer' at http://www.adobe.com/devnet-docs/digitalpublishingsuite/ContentViewerForWebSDK-2.0/modules /What's%20New.html. -
I am a new iPod shuffle 4th Generation user and I cannot sync the music in my Windows Media play to my new iPod, can someone help?
Hi Daisymae3,
The iPod shuffle does not use Windows Media Player to sync, it uses Apple’s iTunes application, available for free from this web site -
Apple - iTunes - Download iTunes Now
http://www.apple.com/itunes/download/
See also the manual for your iPod shuffle -
User Manual iPod shuffle
manuals.info.apple.com/MANUALS/1000/MA1550/en_US/iPod_shuffle_4thgen_User_Guide .pdf
Specifically Chapter 3 - Setting up the iPod shuffle.
iTunes is the free software application you use to set up, organize, and manage your content
on iPod shuffle.
Thanks for using Apple Support Communities.
Best,
Brett L
Maybe you are looking for
-
White MacBook discoloured by use of Tucano Second Skin folder
I have a three month old white MacBook which I protected from new with a black Tucano Second Skin folder. I've discovered discolouration on the case at either side, matching the internal design of the sleeve. I've used iKlear, with no effect. Anyone
-
I need one parameter value to return all values in SSRS
when clicking on last label , I need data associated with all counties to retrieved , it is working fine when clicking on particular country but I can't figure it out how to do this is with multiple value in my SQL code I am trying to do this wher
-
I am trying to understand why the battery life on my recently purchased Macbook pro is 3-4 hours. Does anyone have this same problem?
-
Hi, Now I'm in trouble. I was working last year with a MacBookPro and FCPX. Everything nice and well. I dediced to upgrade to MacPro, so I did a "backup" of all my Events and Projects folders of the MacBook Pro, and waited for the MacPro arrival... N
-
The Playhead Function in the iOS7 Music Player
I am having troubles with the playhead function with the new music app for the ios7. If I am playing a track and I want to use the playhead function whilst playing a track it at times lags and often bumps to different part of the track. The playhead