ActionScript 2.0 :: Using SetMask Method With Multiple MovieClips?
Dec 3, 2004
Trying to use the setMask method and having trouble. I have it working on my dynamic text, but I am trying to mask the movieclip that is loading my image from the server. I have a moviclip called Comments. And in it I have movieclips called textbox and image
I have one setMask AS like this for the textbox
this.textbox.setMask(this.mc_mask2); - this one works
But for image I have the same thing and it doesn't work. I have
this.image.setMask(this.mc_mask);
View 3 Replies
Similar Posts:
Apr 11, 2007
say i have a method "btnClick", and i have 5 buttons: btn01,btn02,etc.. how do i apply this method/function to the 5 buttons through code? here is what i am trying to do(this is just pseudocode):
Code:
MovieClip.prototype.btnClick = function(img){
this.onRelease = function(){
open(img);
[Code].....
View 6 Replies
Oct 14, 2008
The section in my code that does the rotating is in _root.onEnterFrame. Each movieclip is moved up/down an notch at a time within a 'for' loop. this loop is within a larger 'for' loop depending how many catagories to move up/down. I shall include this section of code for; i hope, better understanding
View 2 Replies
Feb 5, 2012
[Code].....
I have a group of 16 images that I would like to load 1 of each into each movieclip. I want image1 to be inside of visual1, image 2 inside of visual2, and so on. the images are named like, 1960s_(1).png where the 1960 (year) part is coming from the rangeNum variable. The above gives me this error: 1061: Call to a possibly undefined method addChild through a reference with static type int.
View 4 Replies
Sep 16, 2009
I have 50 images that need to be on stage, which will be embedded into 50 different movie clips. I named the movie clips image1-image50 and the images are in an external folder named 1-50. Every freaking article or tutorial I have found clearly explains how to upload one image, or just one at a time. I can do that, and spend 2 days renaming all the functions, but I do not want to do that. Is there a better way to just load all 50 images, place them accordingly?
View 3 Replies
Oct 26, 2009
I have 24 movie clips on the stage: my_menu.image_holder_mc1 thru my_menu.image_holder_mc24. I want to load an image in each one. How do I identify the holder which to add a child.
The Code I have so far is....
Code:
for (var i:Number=1; i<=24;i++){
var myLoader:Loader = new Loader();
myLoader.name = "image_"+i;
[Code].....
View 2 Replies
Feb 4, 2009
I have very big problem with generating movieClips at the begining of my code I have two preloaders I'm using createEmptyMovieClip method to create them and then I need to attach some movieClips using attachMovie method and thay are uncompatibile... :/ what shuold I do to make this code work properly...
[Code]....
View 4 Replies
Apr 25, 2006
How do you use a for loop to clear the draw method of multiple mcs?
i guess what i need to know is how to make the for loop increment through the different instance names. they are in the format curve1, curve2... curve3.
View 3 Replies
Jul 24, 2009
I am using Flash CS3 with ActionScript 2.0. I am trying to load a jpg in and display it in an existing movieClip. I have created a movieClip on the stage with an instance name of maskMovieClip. I then create a new/empty clip within maskMovieClip, and then load the new clip with the jpg and then try to use the setMask to switch them. I did read that it won't work if jpg's have not finished loading, so I put a for/next loop in my example just to make sure the clips are loaded.
Here is my test code:
//How to reproduce problem...
//Create one movie clip on the stage with an instance name of maskMovieClip.
//Create two small jpg pics called pic1.jpg and pic2.jpg.
//This correctly loads and displays a jpg into maskMovieClip
maskMovieClip.loadMovie("pic1.jpg", 1);
[Code] .....
View 5 Replies
Jun 17, 2006
I tried to apply setMask() method on loadMovie() - it not works or make I someth wrong?
loadMovie ("main_anim.swf", container_mc_main);
container_mc_main._x = 477.8;
container_mc_main._y = 49.5;
[code]....
View 2 Replies
Aug 19, 2009
Suppose I have 3 mc's : mc1, mc2 and mc3.trying to do mc1.setMask(mc2) works fine.then if I try to apply another mask on mc1, the last mask will work but the first one already applied will not.[code]Only the last mask will show.I tried to search for documentation on setMask but without any luck.
View 9 Replies
Jan 5, 2011
Multiple value passing Querystring using flash array method into asp file ?
trying to work with the code but not passing any value ?
Code:
for (var i = 0; i<newArray.length; i++) {
var num = i+1;
pas["n"+num+"="] = newArray[i].name;
[Code].....
how to pass multiple querystring to html or asp ?
View 1 Replies
Dec 16, 2009
How do I accept multiple arguments in a custom method? Like:
Proxy(101, 2.02, "303");
function Proxy(args:Arguments){
Task(args);
}
function Task(var1:int, var2:Number, var3:String){
// work with vars
}
View 2 Replies
Apr 30, 2011
I am writing a program that requires the use of 36 boolean variables with different names (e.g. box1, box2...): does anyone know of a quick way to optimize this program.
View 5 Replies
Jun 30, 2009
i need something in this script for make mask to all the menu now i stell don't understand why just last menu is mask i have var( i )Start from 0 to last number the menu example: last number menu is 9 so will mask just the menu number 9 i need not just to mask menu number 9 i need to all the menu menu loanding from xml and i make the script for linkage i tray so much for finish the problem for mask all but .... this is script:
[Code]...
View 9 Replies
Jun 17, 2010
I've got a movieclip of a rectangle in my library which I place on stage to attachMovie. Then I create an empty movieclip which I want to use as a mask on that rectangle clip through setMask. Users kan draw into that empty movieclip. My intention is that only those areas of the rectangle clip become visible where the user is drawing a line. So I used this:
[Code]....
View 4 Replies
Jun 26, 2010
I'm working on an AS2 website that uses some alpha gradient masks in its header's looping animation. If I put this animation on the main timeline my masks work perfectly [setMask()], but, because the header needs to be a movieclip, my masks don't work at all.?
View 2 Replies
Jun 1, 2005
i have had this file sitting around a while and what i would like to do is make the blob/bubbles mouse trailer actually set as a mask for an image or mc. all the code sits on a small control clip just outside the stage.
here be the fla - blob.fla
also any hints on how to get this little thing to work in MX 2004 ?
View 4 Replies
Jun 22, 2006
Got a movieclip masked by another one with onLoadInit and setMask. Everything works correctly on local but when I use the same swfs hosted on my "server" the mask simply doesn't work, losts its function and shows over the other movieclip as a box.
View 2 Replies
Dec 1, 2004
I am using the following code to generate a television unit that will load in various SWF files and obviously, I want to mask the viewing area of the television ONLY. The SWF is loaded on level 4, while the panel and buttons appear on lower levels. Problem is when I attach a mask from the library to the movieclip containing the SWF, nothing happens.
Here is my code...whats wrong with my final section (MASK)?
//create empty movieclips to hold contents:
//***** DYNAMIC PANEL - Level 1 *****
myExpanded = this.createEmptyMovieClip("expandedContainer", 1);
expandedContainer.attachMovie("expandedPanel", "expanded_mc", 1)
[code]....
View 7 Replies
May 4, 2010
The argument to my method func() must implement the two unrelated interfaces IFoo and IBar. Is there a better way of doing this than declaring another interface only for this purpose that inherits from IFoo and IBar and using that interface as the argument type?
[Code]...
View 2 Replies
Dec 2, 2009
i want tht the part revealed by the mask mcmask movieclip created through AS only shud be displayed...but it doesnt.i create the mcmask dynamically and set its width n height dynamically. through AS.when i trace the mask width it shows it as 0.
View 3 Replies
Jun 26, 2010
I'm working on an AS2 website that uses some alpha gradient masks in its header's looping animation. If I put this animation on the main timeline my masks work perfectly [setMask()], but, because the header needs to be a movieclip, my masks don't work at all.
It doesn't matter whether I tick the cacheAsBitmap property in the properties panel or I set it to true with AS for both the mask and masked mc's. I even tried with both, ticking and AS at the same time, but as long as my masks are inside the header mc, they're not working.
View 6 Replies
Jan 7, 2011
I've tried to be very descriptive on title, cause i have found around loads of "setmask does not work on dynamicly created mcs'. My case quite differs. =x
I've got 2 mcs, one holds an gradient and the other is the loader. The image is loaded using the loadmovieclip class.
First I've tried to set the code in the mc that holds both. Failed. Also tried setting on parents, and onLoadInit. All failed.
Ps: Surelly I've done double testing for each time I've tried. Firstly I would try placin an image inside the loader mc, to be sure the code was working without the load, and only then check with loading.
View 3 Replies
May 14, 2004
I am trying to use apply setMask to a movieclip which loaded external jpg's.
The set mask doesnt work and returns the following error:
*** Security Sandbox Violation ***
SecurityDomain 'domain@demoImageName.jpg'
tried to access incompatible context 'file:///C|/DOCUME%7E1/jay/LOCALS%7E1/Temp/Untitled%2D1.swf'
View 3 Replies
Mar 4, 2005
I have a movie with some dynamic text, which is embedded and has aliasing turned on -- it is crisp. This text field is behind a mask that I created using setMask so the text appears. The problem happens when I publish my movie as player version 6. When I do this, the text looks as if the field was on an odd pixel, for example x = 60.4. But it's not.
View 8 Replies
Nov 30, 2007
I've attached two files that are exactly the same except in Mask_symbol.fla I copied the frames from the _root and put them in a symbol.When you open the files you'll see the mask on the _root gets applied at runtime like it should but once you take the exact same frames and put them inside a symbol it no longer works.
View 1 Replies
Jul 30, 2008
I am using movieClipLoader to load a swf into slideHolder
[Code]...
I know that is the right way to do it, but no luck! Whats wrong with it?
View 5 Replies
Oct 27, 2002
if it's possible to apply mask over images loaded with loadMovie(), be it physical or through setMask.
View 6 Replies
Aug 17, 2011
add some functionality to the presentation template. Currently you can only move from one page to the next. So if I want an animation on a page, no problem I'll just add a stop script at the end. No big deal. But if I want Multiple animations (just trying to replace powerpoint here) then I get into trouble.
Each page is one frame on the main timeline. Hitting left/right goes to the next frame, unless the movieclip on that frame also has additional frames. Then it should move to the next frame within that, etc.
I can't figure out that if statement though. I had another bit of script going on my first go, but ran into some issues so thought it best to create all of the scripting on the main timeline. Initially I created a boolean variable, then ran an if statement. Inside of a movieclip I switched the boolean and used the same keyboard interaction to walk through it. On the last frame of that movieclip, I switched the boolean back so the main timeline interaction kicked in again. The problem is, that's a Lot of copying and pasting of that code, and I can't figure out how to go through more than one parent. I just couldn't get it to work.
Should I just be building this thing in a Completely different way? I need to make something, so for now I'm splitting up each frame that I need different animations on and creating a different movieclip for each section. Ideally that would be contained in one movieclip's timeline. Currently one each animation's interaction will be on a timeline. So I have to duplicate the slide to add an animation. So if I have a title come in, then a pie chart, then an image, then another piece of text, I'll be stuck with 4 separate movie clips.
I want something like:if current movie clip current frame is == total frames, clicking right goes to next frame, else go to next frame of it's parent's timeline.I say the parent and not stage because the way you have to set up transitions only works within a movieclip. So you have to set up the entire slideshow within a movieclip if you want transitions between each slide. Right?
I don't care about transitions for now, but will want control of those eventually.
View 15 Replies