ActionScript 2.0 :: Create Masks With Loop And Move Them?
Nov 12, 2003
also think it has been asked before. I searched but couldn't find it so here goes:I'm trying to create the effect where it seems as if a picture is cut up in a number of pieces that slowly ease to their location where eventually they all form one image again. (can't find a proper term for it, sorry)Maybe the attached fla will make things more clear.There must be an onEnterFrame handler somewhere in which the easing is done. I'm not sure exactly how to set it up though.
I'm trying to create the effect where it seems as if a picture is cut up in a number of pieces that slowly ease to their location where eventually they all form one image again. There must be an onEnterFrame handler somewhere in which the easing is done. I'm not sure exactly how to set it up though. Could somebody please have a look?
I'm loading 8 thumbnails via XML, placing in a sprite, and spacing them out with a helper grid class. This part works. What does not work is when I try to assign a mask to each of these (using a simpleRectangle class I made) I appear to only be assigning a mask to the last image. Am I doing something wrong with 'imageLoader.mask = _mask;' ?
My ultimate endeavor here is to click the thumbnail and animate the mask to reveal the entire thumb.I nested the showPictures function so it could have a reference to the masks, which is not optimal.
package public class MiniGallery extends Sprite { //create($columns:int, $rows:int, $xSpacing:int, $ySpacing:int, $xPadding:int, $yPadding:int)
I have an animation I've created of a rotating Earth. I want to turn it into a movie clip, so I can easily use it in other files. The problem is, I can't make it into a movie clip because there are some layers that are masks and they are locked.
I am using masks to create a flashlight effect. I have managed to mask the floor of the room but cant seem to mask the aliens as im unsure what code will mask the aliens.
here is the engine.as
Code: private var thelight:light; private var theplayer:player; private var theroom:room; //private var thebug:bug;
I'm trying to create three circles on the stage, one red one green, one blue. When Red overlaps blue, I want the overlapped area to be magenta. When blue overlaps green, the overlapped area should by Cyan. When red&green, it should be yellow, and when all 3 mix it should be white. How do I create the color effect. Right now I have the overlap constraints working and a simple TRACE outputting the color. I need to know how to create the color effect when they mix.
I know this is very noob, but I need a simple AS move and loop. Move an object across the stage and once out of site, loop and start over again? It needs to be a slow and endless loop.
Is it possible to create multiple layer masks over a single layer using Actionscript3?Below is the flash effect I wanted to create with masks.First it starts from A and goes to B and C simultaneously.Then from B it goes to H and D simultaneously (the same applies to C).This is how the end result will look like.ps. I need my background to be transparent. I'm embedding it into a web page later.
Originally posted here at PvP forums.My problem essentially consists of finding a way to make masks *hide* what they cover, rather than to hide everything *else.*
I using a for loop for a redundant action that I want to happen across 5 buttons. OnRollOver the button rotates. OnPress the button moves to a new position. It looks like this:
Code: for(i=0;i<5;i++){ _root.swatch_mc['swatch'+i].onRollOver = function () { this.onEnterFrame = function () {[code]....
My problem is this; onPress I want the button to move up (Ive achieved this already). I also want the other buttons to move down onPress (this is my problem). Is there a way have the other 4 buttons move down onPress using the for loop? Or is there another method of doing this?
Although this is so basic, I need some sum recollection refreshing on moving an MC across the stage. In fact, I really need sum codez to store in my actionscript archive in the event that my memory gets suddenly jaded, as it does sometimes. Thus, for example, I want my MC to move from right to left and loop continiously? something like Kirupa's footer on the bottom of this page? How would I set up the variables and the actions for that?
I'm working on Flash CS3, ActionScript 2.0 on a project assignment for my class. I'm working in 6 different scenes within the one file. I have Scene 1 on a loop, but need a button that is clickable within the loop to move the program onto Scene 2. I have converted the image I want to a button, but I do not know what to do next in order to make it link from Scene 1 to Scene 2.
I'm trying to make a simple for loop that makes a line move. But it won't work, and when i search for "for loop" it gives me all these dynamic things that are WAY over my head.[code]The way i see it, the i should increase by 1 each time the loop is run, and then the line will move up by 1 until it is at x = 0 (it starts at x = -77). But when i preview it in flash and html, nothing happens at all.
I'm aiming to create a website that works just like this one[url]...
I want similar features, ie; rotating and expanding text controlled by mouse events and drop downs.
I'm not concerned about the drop downs currently, but for all I can think of right now, I am trying to figure out the best way to complete this task, and the code (AS3) that would be needed.
I've come up with a few thoughts (forgive me as I'm only moderate at Flash- can code, remember most of it, understand it, but can't always come up with the solution off the top of my head)
I want to create a preloader that is essentially a block of colour moving across the whole stage (610 x 300 pixels) - i don't want it to show the percentage loaded, just the colour will move across the screen and obviously when it reaches the other end, that will indicate that it has loaded all the external swfs and goes onto play them....
I am trying to create a movie where several movieclips move towards the center of the screen and organise themselves. I havve the following code attached to the timeline, the clips move ok but dont interact.
Code: target_mc = ["mc0", "mc1", "mc2", "mc3"]; movement = function () { numMcs = target_mc.length;
Any link or flash file which explain how to apply mouse move effect on images of gallery. I mean image sof gallery simply move with mouse direction and stop on mouse stop.
I have done the research a lot but failed I need to give the effect in flash like this any one know how to do that please send me any hint or peace of code so i will get
I have been struggling to find a way to do this. Basically, I am committing data to a database that I have assigned all the variables to. However, when it has finished committing that data, I want it to then push to the next view. So far, I can get it to work if I program in another button to push to the next view but I want it to be automated with the one button.
So far my code is:
protected function btnClientSubmit_clickHandler(event:MouseEvent):void { repID = RepID.toString(); CompPass = CompID.toString();
[code].....
It works 100% for committing so that is not a problem and hence I did not include all the other code. My problem comes with the fact that the program is pushing to the next view too soon and it interrupts my data insert.
I am trying to create a movie where several movieclips move towards the centre of the screen and organise themselves. I have the following code attached to the timeline, the clips move ok but dont interact. What am I doing wrong!?
I am trying to create a slider that will move a series of images in a movie clip based on the location of the slider. The problem I have is that when you click and drag the scroller it will move the images once but after that the images will not move. I am guessing that the problem is with my code. I want to move the _x of the images movie clip based on the _x of the slider. Here is the code I am using which is placed in frame one of the "timelineSlider" MC:
[Code]...
If it will help I can send the the original .FLA file by email as it is too large (225kb) to post on the forum.
I'm trying to create a number of similar variables using a for loop, rather than having to explicitly write out each variable. For instance, I need 9 variables called zone1, zone2, zone3 etc. So rather than writing it out like so...ActionScript Code:public var zone0:Zone = new Zone(); public var zone1:Zone = new Zone(); public var zone2:Zone = new Zone();// etc. etc. After a look around on the internet, I came up with this, however, it doesn't work...ActionScript Code:for (var i:uint = 0; i<=8; i++)public var this["zone" + i]:Zone = new Zone