gotoAndPlay ("label") going on at different times of second click HTML5 canvas

I have a very strange problem, I can't seem to understand.

I work in CC animate with a HTML5 canvas.  I made a simple interactive slideshow that a user can jump around in.  Instead of going to the chassis numbers, I use labels for each button.  My key codes look like this:

This. SL01_01But.addEventListener ("click", fl_ClickToGoToAndPlayFromFrame_2.bind (this));

function fl_ClickToGoToAndPlayFromFrame_2()

{

createjs. Sound.Stop ();

this.gotoAndPlay ("Slide02");

}

I have to stop the sound, then go and play an image tag.  It works on the first click, however, if the user sees this new framework, on the second click goes to the next section (the one after the label).  For the life of me I can't understand why.  Any ideas?

So what you see is expected.

you will stop on Slide02.  and then a gotoAndPlay will leave Slide02 and get arrested on the following image, before he gets to Slide02 again.

That is to say, your gotoAndPlay runs and then the this.stop () runs in the Slide02 more 1 frame.

to remedy this, use this.gotoAndStop ('Slide02') for not going out when rerun.  But if you really want to get out and then re-enter that govern when you could use:

this.gotoAndStop(this.currentFrame+1);

this.gotoAndStop ('Slide02');

Any reason you have to want to do this is probably better handled by other code.

Tags: Adobe Animate

Similar Questions

  • Time Machine - an exclusion different backup for the backup drives different time machine

    I hope someone can help me.

    For these past years, I used 2 Time Machine backups to keep all safe. I have 1 backup x who lives at home and is 3 times the size of my disk. I also have a second drive of laptop that I travel with, which is partitioned to give a little time machine backup, more than 1.5 TB of "overflow storage (for movies, video files, etc).

    Recently however, I realized that my "storage of listening" actually contains a large amount of data I wouldn't lose (especially the photos of my children because they were born), so now I want to save this drive as well.

    If my ideal situation is to have a huge drive I leave at home. This contains backups of the computer AND 'excess of storage' backup. It's pretty simple to implement.

    But can someone tell me if my trip backup, will try also to the other partition of the backup drive? And if so, is there anyway to give different time machine backups different exclusions.

    Hope that makes sense and hope that someone can help me.

    Thank you
    John

    You will need to manually change the exclusions when you going on a trip. There isn't a way to change automatically.

  • Work on App and travel to different time zone

    What happened to my circle of training and records when traveling to a different time zone?  Will be my streak get screwed up by the different time zone?

    Thank you

    J

    This will depend on when you switch to the different time zone.  Will travel you East or West?

    • If you are traveling to the West and extend the day, pass the watch to the new time zone, before midnight the previous zone.
    • If you are traveling from the East and the day is shortened, switch back to the previous zone, the day before that I sup, if you need complete rings.

    I posted my results for the purpose of 'stand' here: How to extend the day after midnight to complete activities and close the rings

    If you wish to extend your day past midnight to close the activity temporarily put rings the time zone to time zone more West.  Change the time zone by midnight. Now, you can use the overtime that the timezone is offset from your usual time zone to complement the missing activities.

    I tested again on a long distance flight, where the time zone to destination is shifted 8 hours than my home timezone.

    As you can see, watch OS 2.1 may give credit for activities for more than 24 hours if change you the time zone.

    At 17:00, the watch already showed that 25 hours of 'Beneficiary', more than a day.

    And with the 8hrs offset in my regular zone I could have accumulated 30 stand hours in work a day of:

    If you wish to extend your day to complete the activities in this way, do not forget to set the time zone before going to sleep, or you may forget the next day that the watch is a few hours off the coast. I'd wait to set the zone time back until after receiving the message that all tasks have been completed for the day and set the timezone to the correct time after the next hour.

  • How can I Albums in the Photo App with images taken at different times.

    How can I Albums in the Photo App with images taken at different times.

    I had books in Aperture and iPhoto which have been labeled 'Family', 'Friends', etc., and I would like to move the images in the album, and there no matter when it was taken.

    Thank you

    Brian

    In the same way. Make an Album and drag the images to him. Key word or images and the use of the smart Albums.

  • Add an event (Touch) at different times to a symbol?

    Hello

    I searched to see if this has been answered. However, nothing seems to solve completely.

    The problem:

    I have a design of the tablet with several pages (three pages) and that a single arrow to move between pages in the lower right corner of the screen.

    In theory, a user can press the button and the first page would deconstruct offshore and the next page would be inspired.

    I would like to do this for each page, if a user can tap through the whole experience without knocking swipe, a loop to the first page. I was able to configure easily get on the first page

    on the second (this example uses the symbol for a touch event using triggers to start and stop).

    The Question:

    How to make a button (symbol) do the same action at different times? For example, 1 to 2 seconds, the button action going from page 1 to page 2. In 2-3 seconds, the button would then switch to be any another event for transition from click

    between 2 to 3 pages?

    I don't want to have to build several buttons and would rather resolve this problem in the code.

    Thanks for any help!

    Best,

    S

    Hello

    So, your arrow will have a click with a conditional statement event:

    If (sym.getDuration () == 1000) {sym.play(1000) ()} //page 1 is displayed

    ElseIf (sym.getDuration () == 2000) //page {sym.play(1000) ()} 2 displayed

    ElseIf (sym.getDuration () == 3000) {sym.play(1000) ()};  page 3 posted

    I assumed you put triggers in 1000, 2000 and 3000 with sym.stop ();

  • gotoandPlay won't do not to the correct second time through image tag

    Im having trouble with this simple project, I am working on. Its base all.  There is a back and a button continue at each image. The first picture play until the 50 chassis I have labeled "slideone." The code for this frame is:

    Stop();

    back_btn.addEventListener (MouseEvent.CLICK, backFrame);

    function backFrame(evt:MouseEvent):void {}

    gotoAndPlay ("intro");

    }

    continue_btn.addEventListener (MouseEvent.CLICK, continueFrame);

    function continueFrame(evt:MouseEvent):void {}

    gotoAndPlay ("slideoneend");

    }

    By clicking the button continue, takes you to the next series of images that has two buttons again and the code:

    Stop();

    back_btn.addEventListener (MouseEvent.CLICK, backFrame1);

    function backFrame1(evt:MouseEvent):void {}

    gotoAndPlay ("slideone");

    }

    continue_btn.addEventListener (MouseEvent.CLICK, continueFrame1);

    function continueFrame1(evt:MouseEvent):void {}

    gotoAndPlay ("slidetwoend");

    }

    This happens about 4 times where he buttons are clickable to go to the next series of images, and it works perfectly fine when I ran it the first time, but by clicking on "continue". When I decide I want to go back and watch the previous slides and then click on continue again, he won't have to the frame. It jumps to the next image tag.

    Anyone know why that would happen?

    If this code buttons are continuous along the layer of the timeline (not), they inherit the code of the previous (s) and vice versa.

    What you can do is rather just have a function for forward and a back for the entire timeline and have these functions use variables for image tags.  In the new images of the section, you assign new values to the variables rather than assign the new code for the buittons.

  • Satellite P200-1JV - screen begins to blink in different times

    Hello!

    I am owner of a Satellite P200-1JV since last week and three days ago I had a strange problem.
    My laptop * screen starts flashing * in different times.

    The flash frequency increases by 3.4 times to 10 +.
    In addition, the number of times to flash occurrence increases significantly.

    The blinking persists even if I do * not * activate any program.
    All programs are by default.

    Everyone knows the same problem before? Any solution?
    The graphic problem (ATI Mobility Radeon HD2600)? Or is it a manufacturing problem?

    Could you please help me?
    Thanks for in advance!

    What do you mean by manufacturing problem?

    It very difficult to imagine that how the display flashes or what might the case these flashing but it certainly looks like a hardware problem.

    If its hardware issue you will need to contact a technician from Toshiba for a fix. I think it's clear

    The P200 seems to be a new laptop and my knowledge, the guarantee must cover all
    So, don t waste time and ask an ASP in your country for a control from laptop

    Good bye

  • Photos create two different times.

    Sometimes Photos create two different times with pictures of the day. How can I join in an instant?

    Thank you.

    You can not - moments is totally automatic and you have no control of it--tell Apple what you want - http://www.apple.com/feedback/photos.html

    LN

  • Write several bays in one xml file at different times without overwriting the old file?

    Hi my name is Dustin,

    I am new to labview and teststand... I try several tables of data in a single XML right. I can do this with a cluster but I need to create a variable for each of these pictures (21 pictures) and I was hoping to use the same variable for each table. Which means that I get my data table write in an xml file and replace this table in this variable with a new table and then call my VI who writes this table in an xml file and write to the same file xml under the first table without crushing. My VI I created to write a table to an xml file is attached. Yet once I wonder if there is a way to write several berries in a single at different times xml file, without overwriting the old file xml.

    Thank you

    Hi dlovell,

    See the attached example. I think he can help you.

    Kind regards
    Nitz

    (Bravo to give good answers, mark it as a Solution If your problem is resolved)

  • How do I set the power for different time?

    Hello everyone,

    I try to set the different value of RF power for different time as shown in the figure. To do this, I tried using the timer 'Elapsed time '. A counter that counts each time is an array index, as shown in the attached VI. But, the meter does not not.  I didn't know what went wrong. would you lelp me please?

    I thank very you much.

    I would like it.

  • How do I either set channel name of a graph of cluster or get a 1 d waveform chart to start different time (t0) for each line of the waveform?

    I have a chart single 2D out a conditional of a loop indexing output such that over the rows of the table are not the same size. -Basically, they have different starting and ending points and sizes. -Not so concerned by the endpoints, because as soon as I get correctly starting points, everything shows fall in place.

    The challenge is that when I try to have the variable t0 (start time) for each line, the wave of construction vi form would always keep each line at the same starting point.

    I used the approach bundled with success (the cluster approach ensures that each waveform starts at different times according to the guidelines of my t0 defined for each line) but then I'm not able to get in the channel names I could make using the graphical approach (wave generation) waveform.

    In essence what I get here, I'm losing here.

    Because I don't want one of my mentors, Bob and Altenbach have fed up with me I have attached a vi this time

    Attached VI shows a combination of the two attempts (first with the waveform graph) and then with the graph of cluster

    1. with the first (graphical waveform), I get my channel names as you wish, but the alignment of the wave is not correct.

    2. with the second (graphical cluster), the alignment is good, but I can't do the names of channel in the chart, even if they are present in the cluster.

    I read some reviews that mentions that attributes can be displayed with waveform and data Dynamics (not clsuters) so I guess that's why.

    I saw another report indicating the start time for a waveform 1 d will always remain the same for the rest lines defined for the first line even if changed for the following lines in a loop.

    So I guess my question is: what is the way around questions like that?

    First of all, let me be the first to the congratulate and thank you for finally posting a code!  I'm not 100% certain I understand your question or your code, but I have an idea, perhaps, of what you want to do, so I wrote a little VI who made something simple that could be relevant.

    You mention waveforms of different lengths and beginning at different times.  You also want everyone to have a unique attribute (although I'm not sure what you want to do with the attribute).  So, I did the following:

    1. Generated an array of 100-sample random to represent one second of a waveform.
    2. Created 4 waveforms on this 100-sample basis.  The first waveform (channel 0) is just these 100 points.  The second, 1 channel, is the concatenation of string 0 with the base of 100 samples, or a waveform "double".  Channel 2 is 1 string concatenated with the base, and channel 3 is 2 string concatenated with the base.
    3. In order to trace the four channels that they rest 'on' the other, the waveform has the number of the channel added to it.  Channel 3 is 3 + (4 copies of the basis of 100 points), a waveform 400-point random centered around a shift of 3.
    4. All channels have dt value 0.01 (but I guess I could have varied, as well).
    5. To make the channels start at different times, I started channel N N seconds before channel 0 (by subtracting the index of the loop, I, T0).
    6. For each channel, I created an attribute called "Chan" equal to "Channel N" (where N = 0, 1, 2 or 3, as the case may be).

    This is the plot that results. Scale X is the absolute time value (no Date) using the 24-hour HH: mmS format.  You can see that the plots are 1, 2, 3 and 4 seconds of time, and are offset from each other by a second.  I used the trace attributes to change the name to the respective attribute.

    The code to do this is very simple - I almost don't need to show it, because I think it is completely described by the text above, but this is here:

    Now, it was not that much faster that some of your previous posts, when you refused to your postcode, "guess us" what you wanted (but not to not correctly guess), you tried to "push" us in the right direction (still refuses to post code), and no one seemed very happy?

    Bob Schor

  • How do the count meter or begin at different times

    Hello

    How to let the counter count time, that does not begin at the same time?

    This timing system is a system of sports timing for the canoeing competition, it must follow 6 competitor who starts at a different time.

    I have a problem, I have 6 counter in a VI that allows to follow 6 competitor, but it start counting at the same time, how him to account separately for each competitor?

    Do you guys know how to fix this?

    I'm really sorry for the mistake of downloading.

    Please note that my version doesn't have the 'Running 2', 'Running 3 "buttons.

    Hope everything is clear know.

  • is there such a thing as an internet connection timer? I'm lost and then community internet connection g at different times of the day.

    is there such a thing as an internet connection timer? I'm lost and then community internet connection g at different times of the day. I have just hooked to the nbn (national broadband - Australia Network) and have just bought a wireless modem/router 9323 method. I set it up and it worked. I noticed that I have two internet connections when I go to access the internet. one is a broadband connection and the other is nettcomm wireless 9323. What gives with that?

    You have a connection wireless and broadband that you could use one or the other or both. It is recommended to use one at a time. Contact your internet provider and discuss the issue with them.

  • I built in webcam but you want to install and use a second. Is it possible to where both are used at different times?

    I am wanting to install and use a different webcam sometimes but I have a already built in. I installed the other cam.but it says device cannot be used or already in service; I'm guessing that because I already have a cam. Is there a way I can do and use them both at different times?

    Hi Texaslovely

     

    You cannot capture images using two webcams at the same time. You can try to disable a webcam from the Device Manager, and then try to use the external webcam. See the steps below to disable a device-

    a. go to Device Manager, open the Device Manager by clicking the Start button, click on the Control Panel, clicking system and Maintenance, and then clicking Device Manager. If you are prompted for an administrator password or a confirmation, type the password or provide confirmation

    b. in Device Manager, look for the device and if you want to disable, and then double-click the device, and then click Driver tab and click on disable.

    I hope this helps.

  • I play runescape and lately to get java error on my desktop icons very much, they are labeled hs_err_pid followed 3 different numbers, help please

    I play runescape and lately to get java error on my desktop icons very much, they are labeled hs_err_pid followed 3 different numbers, help please

    Hi madsman,

    Thank you for using Microsoft Windows forum

    For better support please give us the exact error code.

    This could well be a virus problem. If your step would be to run a full scan of PC online using the following link:
    http://OneCare.live.com/site/en-us/Center/whatsnew.htm
    Then, go to your Control Panel and open "Programs and features" and tell us what version of the Java Application you have.

    If you have a Version that is older, then you must remove the older version of "Programs and features" and install the latest version by visiting here: http://www.java.com/en/download/manual.jsp

    It is normally acceptable to load new versions of Java on top of older versions, but in this case we want to start over with a latest full version.

    Scroll down a bit to the "Download Windows Section" and download/install "Windows 7".

    After download/install this newer version. Close all windows and applications that may be running and "restart" your computer.

    Then click the link once more to return to the download page and select the link that reads "Check Java has been installed properly" If the application downloaded/installed correctly then this test will let know you that Java is working properly.

    Your last step would be to run a malware scan using this link:

    Malicious software removal tool: http://www.microsoft.com/security/malwareremove/default.aspx

    Kind regards
    Aziz Nadeem - Microsoft Support

Maybe you are looking for

  • RN104 adding third disc is very long

    Hi all I have a readynas 104 with 2 x 2 TB disks (XRAID). They are 95% complete data, so I added a third 2 TB drive. Because I added the third disc from the drive I can't view the NAS administration page more. I added the player and the volume has no

  • 110 - 000z: desktop icon

    I just want to know why some icon work and not an icon. I can reinstall them, and it still doesn't work. I can click on the icon, the little blue ring lights and stop. What's wrong.

  • I can't open a zip file because when he saves, he is not a same folder open or "rip"! What is going on?

    I am trying to download fonts on my new laptop, using www.dafont.com. I used this source to download fonts to countless times on my previous laptop. I have windows 7 and now I also have WinZip and whenever I download a font zip file, it asks me if I

  • Y at - it an update for Microsoft Digital Image Pro 10 vs 10.0.612.0

    Is there an update for Microsoft Digital Image Pro 10 vs 10.0.612.0?  I just bought a new desktop computer that is running Windows 7.  My previous office was Windows XP.  I can open my photos in 10 Pro, but I can't do a SAVE AS.  In the upper left co

  • calling functions from c ++ JavaScript

    It seems to me that only the functions Q_SLOT can be called from an external javascript file. For example ButtonID.Clicked () works, while buttonid.isEnabled () does not work. How to call functions like this from javascript?