ActionScript 2.0 :: "if" & "else" - Clips, Appear On The Stage On Frames 1 To 10 And Disappear From 10 To 20?

Feb 3, 2005

in this website, I have 2 movieclips. First one called "elearning" and second one called "website" (I mean the istances names).Each of this movie clip runs trough an animation of 20 frames splitted in 2 parts. So it starts from frame 1 and stops at frame 10. Than a button will command it to run trough frames 10 to 20.What I want to achieve is that if one of the two clips is on frame 10, than the button should command one clip to go from 1 to 10 end the first one from 10 to 20. To explain better, this clips, appear on the stage on frames 1 to 10 and disappear from 10 to 20.This button should command the elearning clip to disappear ( and so to go from frame 10 to 20) and at the same time it should command the website clip to appear on the stage.But if the elearning clip is already hidden, it should stay hidden.I have tried to write this piece of code but it does not work. Cause when I click on the website movie, it will command the elearning clip to go from 10 to 20 anyway, and it does not check if the elearning clip is hidden or shown.

Code:
on (press) {
_root.website.gotoAndPlay ("start");[code]....

View 5 Replies


Similar Posts:


Professional :: After Saving, Certain Frames Disappear?

Mar 20, 2012

With CS5.5 on OSX, after saving a file and reopening it, certain frames (and their artwork) end up missing, i.e. aren't saved with the rest of the file. This happens with random frames. Other artwork, created after these frames, is still there.

View 1 Replies

ActionScript 3.0 :: Getting Movie Clips To Appear And Disappear With The Use Of A Timer?

Mar 23, 2011

I'm re-creating a cctv style project, and I am trying to play flv's at different times using the timerEvent, as the flv's are embedded within one keyframe i need to use as3..

View 2 Replies

AS3 :: Objects On Stage Unintentionally Disappear

Jun 4, 2011

We are making a simple Flash game intended for mobile phones via Flash 5.5 using ActionScript 3.0.We are animating an array of objects vertically until they hit another object at the top of the stage.We instantiate each element of the array with one of 10 MovieClip animations.Each object has two event listeners; one to animate vertically and another to listen for a mouse click(which removes the object from the stage).We run into an issue when more than 10 objects are on the stage at one time.The issue is that the objects disappear sporadically and without explanation. We assume the problem is due to some type of memory/ garbage collection issue.Below is a snippit of our code that dispatches the MovieClip instances onto the stage.[code]What can we do in order for the MovieClips to not disappear?

View 2 Replies

Flash :: MovieClips On Stage Disappear?

Jan 30, 2012

I am creating a miner game (where there are pieces of gold and you have to catch them with hook).I modified the Main class to take all children of MovieClip(root) that has name "Gold" and them put them in an Array(boulders[]) where later check collision (I design and put on stage several "Gold" MovieClips for every level). When the player collects all gold (when the boulders array.length <= 0) then goToAndStop(nextLevel), where again it takes the gold MovieClips from the stage and if it's name is == "Gold" then put's it in the boulder[].

What happened: On the first level(frame 2 cause frame 1 is the preloader) everything is good - I have 2 gold MovieClips on the stage(in design mode) and all 2 gold are put in the array and displayed.

On the second level I have 4 gold and only 2 of them are put in the array and displayed.

On the third level I have 7 golds designed on stage, but only 3 are displayed and put in the boulder array.

It's almost the previous count of the gold(on the previous frame) are subtracted from the count of the next frame gold movieclips.I am placing the Main.as code:

public function createLevel(){
nextLevel = this.currentFrame + 1;
for (var i:uint = 0; i < MovieClip(root).numChildren; i++){[code]....

View 1 Replies

Professional :: Adding Shape Hints Makes Shape Disappear In Between Frames

Jun 22, 2010

Whenever I add shape hints to a shape tween the shape disappears in the between frames. I am using CS5 on Vista. I using files from [URL]to practice.

View 2 Replies

ActionScript 2.0 :: Custom Cursor Disappear When Off Stage?

Apr 28, 2010

I've been going mad trying to find a code that will make my custom cursor invisible when the mouse isn't on the swf.

View 2 Replies

Professional :: Flash Drawings Disappear On Stage

Apr 14, 2010

I'm attempting to learn flash using Adobe CS4. I've found some really good tutorials, but I can't use them because every time I draw something on the stage, the resultant drawing disappears immediately after I release the mouse. Since I can't see it, I can't select and manipulate it. I captured the behavior and stuck it on youtube. I don't have a mike on this system so there's no sound. [URL]. If I create the file with ActionScript 2.0 instead of 3.0, I get outlines of the objects, but not the objects themselves. That's not on the vid, but I'd rather use 3.0 anyway.

View 3 Replies

Professional :: CS5: Two Make Objects Disappear That Are Off Stage In SWF?

Sep 24, 2011

lets say I have animated a car entering the stage area from outside the stage. When I render the SWF at first only the content on the onstage area is visible  but if I resize/enlarge the window I can also see the car(content) lying outside the stage just like in the flash file. How can I make sure that no off stage content is visible at all in the final SWF?

View 4 Replies

Professional :: Objects On Edge Of Stage Disappear In Video?

Aug 16, 2011

I am a newb to Flash CS5 Pro, so I can't tell what is wrong. I have multiple objects on my stage that I copied to create afull effect. Most of the objects perform perfectly, but the ones on the edge of the stagedisappear when I export to video. When I zoom in to look at them, they are there,but when i zoom out to fit to page, they are gone

View 2 Replies

Moving Between Movie Clips And Frames Outside The MC?

Sep 24, 2009

I'm Making a catalog on Flash CS4 ActionScript 3.0and I don't know ho to move between movie clips using buttons and action script...In Scene 1 I have 2 framesIn frame 1 y have a movie clip (MC) and inside that movie clip I have 10 framesIn frame 10 of the MC, I want to put a button that will take me to frame 2 of my original timeline (NOT frame 2 of the MC)an some one tell me how's it done?or if it can't be done that way...then ...How do I go from frame 1 to frame 2 on my original timeline in Scene 1 after the movie clip in frame one is done?

View 5 Replies

ActionScript 3.0 :: Accessing Clips In Different Frames With The Same Name?

Feb 18, 2009

I am using an external class to control a movieclip placed in the stage, which has been drawn in flash. Part of it involves controling the clip's children . Now, the thing is, there is one child having an instance name, say ball, from frame 1 to 10. Then, from frame 11 I have removed this one, and added another child (with another type). I have given this new child the same instance name as the one I have removed. When I try to access object ball in frame 11, it doesn't work.

View 0 Replies

ActionScript 3.0 :: Send Small Gradient Circles Across The Stage And They Somehow Disappear?

Jan 27, 2009

I'm trying to send small gradient circles across the stage and they somehow disappear around x 515. If I increase the size the problem goes away ( though increasing the size to 2px only make them go another 100 px x before disappearing). The problem does not exist with non gradient circles.Here is the code:

ActionScript Code:
package com.xxx.classes {
import flash.display.Sprite;

[code].....

View 0 Replies

ActionScript 2.0 :: Altering Movie Clips On Different Frames?

Jun 27, 2009

how can you set it so that you can click a button, and it will make a movie clip goto a different frame- on a different frame?

View 1 Replies

ActionScript 3.0 :: Accessing Movie Clips On Different Frames?

Jul 9, 2009

How do I make a button on one frame (on the main timeline) tell a movie clip on another frame to go to a certain frame inside that movie clip?

To do this, if the mc's are on the same frame is easy because you just use the dot syntax or MovieClip(parent), but how would I do this if a mc is on a different frame?

View 2 Replies

ActionScript 3.0 :: Controlling Movie Clips On Different Frames?

May 22, 2010

I need to make some animation working without changing its structure, but I have no idea how to control mc instances on diffrent frames and diffrent movie clips. Below is example.When button is clicked, mc2 starts to play.

View 2 Replies

ActionScript 2.0 :: Movie Clips Appearing In Later Frames

Nov 17, 2010

I have an action in a frame that controls multiple movie clips. It doesn't seem to work on clips that don't exist in the first frame. Is that a normal part of AS2.0?

View 1 Replies

ActionScript 3.0 :: Textfield Embedfont Makes The Text Disappear/invisible On The Stage?

Jun 24, 2009

when i set embedFonts to true, the textfield cant be seen on stage. but when i set it to false, it appears on stage. whats going on?

Code:
var newTextField:TextField = new TextField();
newTextField.text = "Hello Ayumilove";
newTextField.alpha = 0.5;
newTextField.embedFonts = true;
addChild(newTextField);

View 6 Replies

ActionScript 3.0 :: Create Movie Clips Dynamically And Add Frames To Them?

Sep 6, 2009

Is it possible to create movie clips dynamically and add frames to them? Because say I have a game and there are NPCs, I'm not going to want to create say 50 different MovieClips manually, is there a way to do this through code?

View 5 Replies

Flash8 :: Playing Movie Clips On Different Frames From A Button?

Apr 9, 2010

I have a button which when pressed I need it to play a frame on the main timeline which contains a movie clip. I also want the same button to play another frame with another movie clip after the previous frame has finished playing. I have attached a sample file of what I am looking to d

View 18 Replies

ActionScript 3.0 :: Wait To Load Certain Movie Clips Or Frames?

Feb 9, 2010

I have seen flash sites that wait to load different parts of the flash file until you click on a link, thereby starting a loading graphic that then loads the content you're looking for. I can't find any information on how to do this, and I'm guessing I just can't find the right terminology.

View 11 Replies

ActionScript 1/2 :: Movieclip Function Affecting Clips On Other Frames?

Jun 7, 2011

The idea is to click on a mc that takes you back one frame (into a different room) and it changes the visibilty of another mc in the new room to false. Here is the code so far:

poodle_mc.onPress=function(){ _root.rooms_mc.safeClosed_mc._visible=false; _root.rooms_mc.gotoAndStop("Office");}

I return to the "Office" frame just fine but the safeClosed_mc is still visible

View 3 Replies

ActionScript 2.0 :: Deduct Current/end Of Frames Of Dynamic Movie Clips?

Feb 19, 2008

I want to dynamically attach movie to the stage. This is fine. I'm able to do it. but i want to check if the dynamic movie clipe has executed all its frames (reached last frame). as soon as this happens i want to attach a diff movie clip. Is this possible? if i use the _currentframe property, it gives always 1 as the frame. it doesnt get to last frame of the dynamic movie clip.

View 2 Replies

ActionScript 2.0 :: Laoding External Images Into Movie Clips In Different FRAMES

Aug 4, 2008

I generally don't mess with the timeline, but I need to for this project. In a nutshell: user can customize a product reference sheet with her choice of crossection, footprint, etc. All those choices exist as external swfs. In order to be legible, the reference sheet must be two pages.I know how to print multiple frames with Flash. But what I cannot yet achieve is loading external swfs into movieclips on different frames, and then print that. Here's my code from a test fla:[code]Now, this code will print both frames as separate pages, but the loaded image in printArea.holder2 does not print!

View 3 Replies

Multiple Movie Clips On Stage - Buttons Not Working In Movie Clips?

Jul 15, 2009

I have multiple movie clips on stage (all in separate layers, of course) as well as buttons on stage to play each movie clip. There are buttons inside each movie clip. The problem is that the buttons inside the top layered movie clip work, but the others in the movie clips below don't.

View 2 Replies

Resize Everything On Stage In All Frames?

Nov 18, 2009

Is it possible to resize everything on the stage in one (or a few) step? I know scaling the movie has the same result, but when working in Flash it's a lot easier when you see the actual size.

View 1 Replies

IDE :: Repositioning Everything On The Stage (across All Frames) With JSFL?

Dec 16, 2011

I have a bunch of old FLAs with one set of dimensions, including a 60 pixel offset along the y axis. I'm writing a jsfl script to resize the stage (works), delete some unneeded layers (works), and reposition everything (doesn't work) What I'm using is:

fl.getDocumentDOM().selectAll();
fl.getDocumentDOM().moveSelectionBy({x:46, y:-60});

When I run my script, the items do in fact get moved, but on tweened clips, they get "doubled dipped," it seems: if I compare the new x and y values of, say, the end keyframe of a clip (only tweened for alpha, for example) is exactly 46 pixels farther right and 60 pixels higher up than it should be.Is there a better way to reposition everything that avoids this "double dipping" among tweens? I'd love to know! There's got to be a way, and I feel like I'm so close, but not quite there. (Of course, I'm probably way offEdit: I've performed the steps manually by turning onionskinning on for multiple frames, selecting all frames, then dragging a selection rectangle across everything on the stage, then moving everything by the desired amount, which works: when I look at the history and view the js for those steps, they look exactly like what I've typed into my script.

View 1 Replies

ActionScript 3.0 :: Loop The Frames When The Movie Is On Stage

Nov 2, 2009

I am just getting back into AS after about 4 years so bear with me. I have a movie that I show and remove as needed on my stage. The movie shows 2 frames of content that pauses between them so the view can see the data. I simply want to loop the frames when the movie is on stage. This is what I have written to control the movie.

[Code]...

View 1 Replies

Actionscript 3 :: Viewing Multiple Frames On Stage

Feb 24, 2010

I want to view all of the frames from within a MovieClip concurrently on the stage, however I am struggling to extract the individual frame information from the MovieClip.I have managed to load an external SWF into a MovieClip and view the frames sequentially with the following code:[code]What is the most efficient way to view ALL of the frames on the screen?

View 2 Replies

ActionScript 3 :: Clicking And Dragging Through Frames On Stage

Mar 15, 2011

I have a frame-by-frame animation. I want to be able to click and drag on the stage back and forth and traverse through the animation. I.e. I want to click and drag from left to right to make the animation go forwards and right to left to make the animation go backwards. How would I achieve this? I am making an assumption that there will be some maths involved in calculating mouse position and traversing to the correct frame, but how would I do this?

View 2 Replies







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