ActionScript 2.0 :: Control Frames At Run Time?
Mar 4, 2006I want to know that how to control frames at run time, I mean how we know that currently I am at which frame (running stage). Can we fetch the value of Frame at runtime?
View 3 RepliesI want to know that how to control frames at run time, I mean how we know that currently I am at which frame (running stage). Can we fetch the value of Frame at runtime?
View 3 Repliesfor my site I am using HTML frames. 1 frame is called "menu" and the other is called "main". I am wondering if there is anyway I can control the .swf in "main" with the .swf in "menu".
More specifically - would it be possible to set a variable in the .swf contained "menu" and then depending on the value, make the .swf in "main" act in a certain way.
For example set the variable within the .swf in "menu" :
myvariable=1
and then do a check within the .swf in "main" :
If my variable==1 {do this} ?
I havn't actually tried "just" doing that because I think it will take more. Does anybody know?
I want to take a folder with 20 pictures, in some way convert them into a movie. And then apply so that I can navigate the frames one by one in the movieclip by moving the mouse right and left (move mouse left - navigate backwards frame by frame, move mouse right - navigate forward frame by frame).
View 2 RepliesI'm dynamically loading a file that will indicate when to show certain words at certain frames. However, I'm having trouble with the concept of timeline control from ActionScript (I'm building everything programmatically in Flash Builder). Let's say my tuples has frame and word:
5, "duck"
13, "cow"
22, "pig"
There is a sprite associated with each. What I would like to do is something like the following:
for (frame in timeline) { //should iterate from frame 0-22 (last frame in list)
if (frame in list) {
list[frame].alpha = 0;
}}
I already know that my display of sprites works and whatnot, I'm just confused on how to play through the timeline in this kind of way, or if it's possible to dynamically do this. Related, can I control how fast the timeline plays? To give a more thorough explanation, I'm looking to visualize word appearances over time in a text. So "duck" may appear as the 5th word in a corpus, "cow" as the 13th word, etc. My list contains tuples of word positions (unique) and the word that appears at that position.
I have a small selection of words that I'm interested in from the corpus, so not every position is represented. I would like to be able to have a SWF movies that essentially starts at the beginning of the corpus, go through my word list in order of appearance in the corpus, and then display the word (and have it fade out). So, if there's a word at position 5 and 10, then should appear in much more rapid succession than if there's a word at position 15, and the next one doesn't appear until 50. Basically, I would like to keep that temporal component.
What I have is a movieclip and a button in scene 1 (which is the main timeline).There is an actionscript layer also on the main timeline. what I want to do is when I click the button, it would do a nextFrame(); in the movieclip timeline instead of the main timeline.
View 4 RepliesIm making a scrolling image gallery basically i have 2 movieclips inside a main movieclip, MC_a and MC_b. MC_a animates the scrolling effect of the thumb panel. within which there are 15 buttons. MC_b has 15 large photos arranged in 15 frames. (1 photo per frame).
what i want to do is when i press a button in MC_a it will gotoAndStop at the frame in MC_b displaying the large photo.
I've tried placing script in MC_b in a layer called "action" and extending it to 15 frames:
import flash.events.MouseEvent;
stop();
Object(root).MainMC.MC_a.button1.addEventListener(MouseEvent.CLICK,pla y1);
function play1(event:MouseEvent):void
[Code]....
I did this for all 15 buttons but none of them works. btw, i am using actionscript 3, Flash CS5
I've set up my flash movie to play and stop at certian frames in the movie. I'd like to add a pause button to pause the movie anywhere in the timeline or animation and then resume from spot it's paused on. This is for a presentation.
View 9 Repliesi have a about 20 frame animation but what I want to do is to find out is there a way to set a time to play a certain frames i.e when movie starts it plays only 10 frames and then stops for a minute then after 1 minute it continues from frame 10 to frame 20 and then again stops for one minute and it starts over again
View 1 RepliesI'm putting together book in Flash. The audio starts with frame 2 but the naritive continues on frame 3 and 4. I can code a "next" button like so:
Code:
on (release) {
gotoAndStop(3);
[code].....
I know it's possible in flash to change one frame of an html frameset with the click of a (flash)button, for example:
Code:
on (release) {
getURL("page.htm", "framename");
[code].....
I'm putting together book in Flash. The audio starts with frame 2 but the naritive continues on frame 3 and 4.[code]...
Is it possible to have code to move to the next frame after a certain amount of time instead of a button?
I have a movie clip and i would like to display its duration in minutes and seconds.urrently I am displaying the frames so it shows "frame 320 of 500" etc.I would like to figure out how many frames in the movie clip and convert it to time so in the end it will display: 1:23 / 3:00
Code:
frameNumber = "frame " + getProperty(movie, _currentframe) + " of " + getProperty(movie, _totalframes);
[code]......
I'm a bit of a newb when it comes to Actionscript 3. Basically I have a movie that a different frames I need it to pause for different lengths of time. So for example on frame 10 I want it to wait 10 seconds before continuing to play and then on frame 20 I want it to wait 8 seconds before moving on, etc. I found some code that I put on frame 10 and it worked fine, but when I tried to put it on frame 20 it generated errors and it didn't pause:
[Code]...
I have a movieclip which has 3 frames inside it. These each have a movie clip on them which is different. There are three frames on the above layer. The first two have code on them which check the date and time and then skips to the next frame if a specified date is reached. The final frame is just a stop as its the final option. So Its works great in as2 but I am trying to rebuild in AS3. I think I am nearly there but since you cant have two of the same function its throwing a wobbler - also when I rename the 2nd function (on the 2nd frame) it wont compile correctly throwing all sorts of errors.
Code:
stop();
addEventListener(Event.ENTER_FRAME, functionOne);
function functionOne(event:ENTER_FRAME):void{
var today:Date = new Date ();
var currentYear = today.getFullYear()
var currentTime = today.getTime();
var targetDate:Date = new Date(2011,05,22);
[Code] .....
I have been tasked with making this happen [URL] - What Ive done is take out footage and include keyframes for each frame (cue points on every frame), which i read helps with scrubbing... and it does. however using an invisible scrubber bar (seekbar) just isnt smoooth enough... So i was wondering if I could register an eventListener on the mouse and when it moved forward, jump x frames/time forward in the flv clip.
View 1 RepliesWhat I'm looking to happen is that on frame 2 I want audio track 1 to play and:
after 1 min 45s move to frame 3
after 1 min 51s move to frame 4
after 2 min 47s move to frame 5
after 3 min 15s move to frame 6
How would I code this or what would be the easiest way to do it??
i want to control a movie clip with two buttons, one backwards and one forwards, the movie is 25 frames long and needs to stop at every 5 frames each time one of the buttons is clicked. Below is some code i have been trying to get to work
[Code]...
I am using the flex flv player component and i want to be able to skip 5 seconds forward and backwards , at the moment from what i understand from the documents it is not acurate because the movie can only skip to keyframes sometimes making the skip 6 or 7 seconds. the same goes to cue points which the flv might miss the actual point if there is no keyframe there/ my question is there any other way to use the player in a more accurate manner ? since i see on the web players that can do these skipps
View 2 RepliesI have a popup that contains a TabNavigator control. The tabs are dynamically added to the TabNavigator when the popup loads. Is there a good way to tell when one of the tabs is loaded, from the tab itself?I have a tab that requires a service call to be made, and I don't want the service call to be made unless the user actually goes and clicks the tab to view it. I could notify the tab from the popup control itself when the TabNavigator index was changed, but that doesn't seem like a good way to go about doing it.
View 3 RepliesSuppose I have movie clips named mc1,mc2,mc3,mc4... In as2[code]...
View 1 RepliesI have three FLV movie files that are places on diffrent frames on the main time line. When the viewer clicks on diffrent buttons I send them to that specific frame by go to and stop action and the flv start playing, but if they click out of that frame by pressing another button the video still plays on the background and they can hear the audio.this doesn't hap stop the video from playing by pressing thepen if they stop button on the flv player.
View 2 RepliesI need to do a countdown time coder showing minutes, seconds and frames (25fps). I've searched a lot but w/out a fish The only similar thing I found is the Kirupa's tut, but I think it's too much graphical (I'd like it only w/ fonts) and actually I'm not so AS skilled Does anybody know where can I start or a good tut?
View 2 RepliesJust wanted to aovid reinventing wheels, I want the date and time picker, I know there is already a date only picker inside flash builder.
BTW: i am using flash builder 4
How can I control the playing time of an external mp3 using actionscript ?
I need to only play a 10 second clip of this sound file so how can I control the length of play time?[code]...
I download a tutorial to make a digital clock now what I want to do is make my movieclips go to a different frame depending of the hour. I want to make that effect of day/night.
View 6 Repliesi read this tutorial, it is about how to control the time line of the loaded swf
[URL]
but i get this error:
TypeError: Error #1009: Cannot access a property or method of a null object reference.
at main_fla::MainTimeline/frame1()
[Code]....
I have a fixed amount of words. Lets say 20 words. I want each of these words to be put into symbols - so i have 20 symbols (box1...box20). Now i want the boxes to fall from the top of the screen and until they reach below the screen. But (and this is where i'm lost) I want to have them fall at different speeds AND I want to control how many boxes falls at a time. Starting out with one box and when this box is out of the screen I want to control the amount of boxes/symbols entering the screen next.
A function telling that next there should be i.e. three boxes entering and falling/floating across the screen (from just above the top of the screen untill they all have reached the bottom). And i want to be able to call a function which starts X boxes - even before the existing boxes in the scenes has dropped). It would be nice to have a function, ie. fallBox(3) , which may be called at any time.
I am trying to implement a small web site in FLash CS3, i have done first phase means i have created 4 pages Home , About us, Group of Companies, Contact us. and i am able to control the timeline like if i click on the home its going to home page and same like if i clicked on about us its going to that page its fine, those first two pages there is no transactions but the problem is, if i clikced on the group of companies here i m trying to create the movie clips and if i clicked on those movie clips then it needs to connect the concerned company web site but here i got stucked even in contact us page also there i am trying to put some more transactions but i am unable to.[code]...
View 1 RepliesI need to get the time in the flvcontrol to trigger a slide image. Where I can find the reference for that control or offer up any code?
View 1 RepliesI'm using Flash MX 2004 Actionscript.
I'm trying to get control of the time line using a conditional statement.
if (myVars.logged == "Logged") {
gotoAndStop(20);
}
I trace the myVars.logged variable and the trace tells me the value is Logged.
But the above statement won't go to frame 20.