Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash




Duplicating Scenes



[Sorry for the double post, but by the looks of it this might be more of a newbie question]

Hello,
I am working on a project for school in flash. I am developing a simple quiz like game that has 5 different sections, each with different questions and results but they all work inherently the same.

I have spent a long time developing the perfect scene that will work for all cases. All I need to do is duplicate the scene, which brings me to my first problem
Duplicate scene just messes things up. When I click on one of my answers to a question it just jumps to the end of the scene. I have tried copying the frames into a new scene, same thing happens. I have deleted all the buttons and then remade them, same thing. I only have a week left on this (one of eight) project and I am desperately needing to find a solution, that wont take too long to implement (my knowledge of flash is limited)

Is there a way to properly duplicate a scene?



FlashKit > Flash Help > Flash Newbies
Posted on: 02-27-2005, 01:43 AM


View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread

Duplicating Scenes
i have created a small flash photography presentation in which images fade in and out from one to the other when the appropriate buttons are clicked.

I would now like to add another series of photos to this presentation, so i created an intro scene which allows the user to choose which series they would like to view. For the new series, i duplicated the existing scene and changed all the instance names of the symbols and within the script.

When I test the scene, it works just fine. When i test the movie however, it gets to that scene and doesn't really do anything. I am extremely confused with this.

The code I'm using is:

//initialize variables and properties
square2._alpha = 0;
whichPic2 = 1;

//initiate change to new image when buttons are clicked
next2.onPress = function() {
if (whichPic2<14 && !fadeIn && !fadeOut) {
fadeOut = true;
whichpic2++;
input = whichPic2;
}
};
back2.onPress = function() {
if (whichPic2>1 && !fadeIn && !fadeOut) {
fadeOut = true;
whichpic2--;
input = whichPic2;
}
};
_root.onEnterFrame = function() {
// when a new Photo is selected, fade out, load new image, and fade in
if (square2._alpha>10 && fadeOut) {
square2._alpha -= 10;
}

if (square2._alpha<10) {
loadMovie("../images2/image"+whichPic2+".jpg", "square2");
fadeOut = false;
fadeIn = true;
}
if (square2._alpha<100 && fadeIn && !fadeOut) {
square2._alpha += 10;
} else {
fadeIn = false;
}
// limit input field
if (input>14) {
input = 14;
}

};

Download the fla file: http://bobcat.bradley.edu/~signal0/presentation.fla

If anyone can help I would greatly appreciate it. I'm a noob and don't know anything.

[F8] Problems With Duplicating Scenes
Hi, I'm working on a project for school, based on creating a game in Flash.

My game basically involves moving through a map of a house. Clicking the doors of the room you are in will link to a motion tween of the map moving in whichever direction to display the next room.

I've got the whole map working so that the whole house can be moved through - and it works perfectly fine, but I want to have the same map available in different states (with a few graphics changed around).

My problem is that whenever I duplicate the scene, all the links stop working properly in the copy - making the movie jump to the first frame whenever anything is clicked.

I'm afraid I cant attatch the fla or the swf files because they're too big for the maximum file size of an attatchment, but I'm hoping that I can at least understand what is wrong.

I've tried changing the instance names of the buttons and stuff, but that doesnt seem to do anything. I'm really new to Flash too so I'm guessing there's something important that I've missed.

Thanks a lot.

Problems With Duplicating Scenes.
Hi, I'm working on a project for school, based on creating a game in Flash.

My game basically involves moving through a map of a house. Clicking the doors of the room you are in will link to a motion tween of the map moving in whichever direction to display the next room.

I've got the whole map working so that the whole house can be moved through - and it works perfectly fine, but I want to have the same map available in different states (with a few graphics changed around).

My problem is that whenever I duplicate the scene, all the links stop working properly in the copy - making the movie jump to the first frame whenever anything is clicked.

I've tried changing the instance names of the buttons and stuff, but that doesnt seem to do anything. I'm really new to Flash too so I'm guessing there's something important that I've missed.

Thanks a lot.

Problems With Duplicating Scenes
Hi, I'm working on a project for school, based on creating a game in Flash.

My game basically involves moving through a map of a house. Clicking the doors of the room you are in will link to a motion tween of the map moving in whichever direction to display the next room.

I've got the whole map working so that the whole house can be moved through - and it works perfectly fine, but I want to have the same map available in different states (with a few graphics changed around).

My problem is that whenever I duplicate the scene, all the links stop working properly in the copy - making the movie jump to the first frame whenever anything is clicked.

I'm afraid I cant attatch the fla or the swf files because they're too big for the maximum file size of an attatchment, but I'm hoping that I can at least understand what is wrong.

I've tried changing the instance names of the buttons and stuff, but that doesnt seem to do anything. I'm really new to Flash too so I'm guessing there's something important that I've missed.

Thanks a lot.

Exporting Scenes Separately And/or Importing Scenes From Other Files
does anyone know a way to import a scene from one file to another or a way to export/publish scenes separately (make each scene a different file)

thanks

Sound Across Scenes & Changing Volume In Certain Scenes..
OK, this is kind of hard for me to explain but i'll try...

I want to have a continuous sound loop over various scenes, but I want the volume to increase (i.e. fade up - and i would like it to fade rather than just suddenly turn up) during one of the scenes.. and decrease (i.e. fade out) to 0 during another scene.

On top of that, I'd like the sound loop to stop altogether when they play another audio file on the movie - then the loop resume when they return to scene 1.

Anyone able to help me here - i know it's sounds complicated but I am sure someone knows how i can do this.

Any help would be much appreciated,

thanks,
Chris

Duplicating
ok, after too many cups of coffee and racking my brain, I am still unable to figure this out. Hopefully some of you OO Gurus can give me a hand.

I have a movie that pulls its content from an external XML file. What I would like to do is set up a loop with actionScript that creates a button for each element that is found in the XML file. I am able to pull the data that I need from the external file, and dump it into an array, but I am not sure how to create the buttons... I imagine it has something to do with duplicating a pre-existing movie clip, but I'm not sure exactly how this would work. Can anyone offer some advice and / or code examples?

Many thanks.
Marty

Duplicating MCs, Take A Look At This Example
I am trying to create a falling snow effect. I am having the following problems with the script below:

1) it duplicates only once
2) the _x does not change after first duplication.
3) also, a bonus question, how can I time out duplication so that all MC don't snow at the same time.

for (i=0; i<20; i++) {
duplicateMovieClip ("snow", "snow" add i, i);
setProperty ("snow" add i, _x, getProperty("snow" add i, _x)+80);
trace (getProperty("snow" add i, _x));
}


Thanks for your help!

Duplicating MC
I'd like to know how to duplicate a movie clip, multiple times, without having to hand-code each duplication, one at a time. For instance, starting with a box on the left, and having it duplicate itself several times (out to the right), with each box getting progressively lighter (using the alpha setting). Thanks.

Duplicating One Mc
Hello-

I'm a little out of practice so I came here to consult the Flash gurus. I want to take one mc and when the movie is loaded I want to duplicate that mc a random number of times (within 40 or 50) then assign each of those mc's random attributes such as alpha level and dimensions.

I'm assuming it'll be some kind of loop to create the mc's then another loop to assign the attributes to each of the created mc's.

I appreciated any and all help.

Thanks
Dan

Duplicating MCs
hi Guys
i need to get this done:
imagine a movieclip with nothing but a button in it, lets call it "mainMC".
first i load a JPG via loadMovie into another MC which is located inside the "mainMC".
now if i duplicate the "mainMC" it has only the button in it not the loaded JPG, and so i have to load the JPG a second time and a third and so on...

is there a way how i could load the jpg only once in the runtime and then use it for all the copies of "mainMC" i need?

Duplicating?
well for a long time now I've been right clicking on the frame and then pasting it to get another frame of the same, I was wondering if theres an easier way of doing this? for example is there a button I ca push that copy's the current frame and pastes after the frame your currently in???

Duplicating Mcs Into Other Mcs
Hi,

Just a quick one. I need to duplicate an mc but have it duplicate inside another mc, this is so i can scroll a list of dynamically created mcs. What do i need to change to the duplicateMovieClip code?

Cheers.

Steven.

Duplicating MC
is it possible to duplicate MC with action scrip from one MC to another.

on root I have MC "A" which has many MC inside let say "a1", "a2",
on root I also have a MC "B" is it possible to duplicate MC "a1" into "B"?

I will really appreciate any help.

Duplicating MC
is it possible to duplicate MC with action scrip from one MC to another.

on root I have MC "A" which has many MC inside let say "a1", "a2",
on root I also have a MC "B" is it possible to duplicate MC "a1" into "B"?

I will really appreciate any help.

I Need Some Help...duplicating Mc
I'm duplicating a movie clip with this...
for(i=1;i<=max;i++){
duplicateMovieClip("_root.menu0","menu"+i,i)
myMenu = _root["menu"+i]
myMenu.mov.txt = nomi[i]

These are basically little boxes that serve as buttons in a menu. How do I code this so that I can put code on each individual button? For example, now if I put code on say, button 2, all the buttons do that same action. You know what I mean?

Duplicating MCs
Can someone help me with duplicating mc's - It's probably easier to explain what I want to do if you have a look st the attached file -

When you click on the pale blue button, the smalledt circle mc duplicates. What I'd like to do is when you click on the button a second time, the duplicated circle also duplicates, so there is 3 circles. I would like to be able to keep repeating the circle's duplicating, so that there would be lots of circles on the screen. I'm not really big on code and any help would be great! Thanks!

Duplicating Mc's
I could just use some general help on duplicating movieclips.

Duplicating An MC Into A Different MC?
Is there a way to duplicate movies into other movies?

something like this:
code:

this.attachMovie("redBall", "ball", 3);

this.createEmptyMovieClip("MC2", 5)

duplicateMovieClip("_root.ball","_root.MC2.newBall ", 8);

Duplicating MCs
If i duplicate a MC, can't i give it a new path. ie. i have a MC on root, can't i put it to _root.blabla.MC??

Duplicating An MC
I am trying to make a game where stuff falls and you catch to get points but I dont know how to make the MC that you catch duplicate so there is more than one falling. I want it to fall from a specific Y axis, but a randon X axis. If there is another Thread about this could you make a link because my board search isnt working.

Help Duplicating A Swf
hey all,

I'm helping my boss work on our website. It's not my job, but i'm pretty much a jack of all trades when it comes to computers (most of us computer people are). one of the things he's wanted was a nice gallery featuring randomly strewn polaroid photos. I made a small gallery by hand in this style, but he's got a few hundred pictures and can barely cut and paste, let alone work in flash.(besides, he'd kick my behind if I told him to do it himself )

I've managed to find a swf that is exactly what he's looking for, but it isn't available as .fla/open source (although most of his other stuff is). I've contacted him about it, but haven't gotten a response, and i'd kind of like to get this done. Here's a link to exactly what i'm looking to find

http://www.jason3d.com/flash/polaroid.html

It looks like his script is just a little buggy, and to be honest I'm excellent with flash, just not as great with the scripting aspect of it. I can read and understand code (and therefore can pretty much chop what i need into a .fla using c&p, but doubt i could code something like this myself.

What i guess i'd like to know is, are there any other movies that are similar to this, or similar enough for me to edit to fit what i'm looking for? If not, how deep would the water i'd be treading in be, if i were to try to code this myself?

Thanks in advance all, hoping for a somewhat fast response, as I've been trying to figure something out to get this done. I might even be able to get my hands on a T-Shirt or two(we've got a small clothing line, in addition to our regular products) to send to someone who is nice enough to try to lend a hand

In any case, thanks for reading

edit : Fixed retardo grammer in the title

Duplicating Mc - How Do I Do It?
yeah so how do i duplicate an MC?

Duplicating Over Another MC
Hey again.

Dmonkey helped me with this problem about two weeks back, and I just started back on my project, and noticed that the code he gave me was near perfection, but still had one big problem. I have an array of weapons in my game, with MCs for each of them within the player MC. Now on fire, I duplicate a bullet movieclip to the weapon's nuzzle, and it will fire at the correct angle. My original weapons were a pistol and shotgun, and since both of these didn't have rapid automatic fire, I never noticed the problem. Once I placed my SMG in, with it's automatic fire, I noticed that when you would shoot, although one bullet would start playing it's animation, the instant another bullet was created, it stopped the last bullet's animation and that last bullet would almost instantly dissapear.

This is the code I use for the duplicating (thanks to dmonkey again):


PHP Code:



//Used attach movie to put movie to the root
            _root.attachMovie("bullet", "bullet"+bulletNum, _root.getNextHighestDepth());
            //made a point object
            var point:Object = {x:0, y:0};
            //converted the tip of the gun (point 0, 0) to a global co-ordinate
            _root.player.arms.weapon.currWeapon.localToGlobal(point);  
            //assigned these global coords to the bullet
            _root["bullet"+bulletNum]._x = point.x;
            _root["bullet"+bulletNum]._y = point.y;
            _root["bullet"+bulletNum].gotoAndPlay("shoot");
            //applied the rotation
            _root["bullet"+bulletNum]._rotation = player.arms._rotation;
            bulletNum ++;





Here is the FLA:
http://denvish.net/ulf/1137380705_wargame_nosound.fla
(Flash MX 2004 or better required)

Thanks!
~ Pol

Duplicating Mc's
I have a game where you control a plane with the arrow keys, and fire with the space bar. I currently have the following code for firing:

if(Key.isDown(Key.SPACE)){
_root.plane_mc.gotoAndPlay("3")
}

Inside the plane_mc, i have a few frames, one with a blank plane, one with the plane and the start of the fire, and one with the plane and where the bullets end up. This is VERY uneffective. I want to have an external mc that is the bullets firing, and i want to have it play from wherever the plane_mc currently is when the space bar is pressed.

If this makes any bit of sense, can anyone help? Tell me if this is too confusing.

Help With Duplicating
I haven't had alot of experience with flash, but I'm trying to write a program where you move around shapes made of four squares (much like tetris), and then place the peices (kind of like a puzzel) and when a peice is placed you get a new peice to place, but I'm having trouble figuring out how to create the new peices.

I figure the moving is just accomplished by looking for key events and moving all the blocks the size of a block each time, and if it collision detects a hit with another block it moves back.

Duplicating Mc
hello, new here, still learning actionscript, i want to duplicate a movie clip or a graphic as i drag the mouse across the screen, is it possible?

i was thinking something like (in simple terms) onMouseMove duplicateMovieClip?

any help you could offer would be great!

Duplicating.
Okay, lets see if you guys can figure out this one.
I want to duplicate a movieClip, so I did. Duplicating works, but there is one problem. I want to duplicate the script with it. Reason? Enemy AI that I am working on. I need them to spawn upon a click.

Duplicating
what is the as3 equivalent for duplicateMovieClip.

Duplicating MC's
Hi,

I'm revisiting Flash after a while and I'm looking at taking it more seriously before as i've built up a background of coding.

Anyway, I am looking to duplicate an MC, I have attached a file, as you can see on rollOver it creates a small animation.

If anyone can help then i'll very grateful.

Duplicating An Mc More Than Once
I have a movie clip blood
and i want to duplicate it 19 times
so i use this code

Code:
ii= 0;
while (ii < 20)
{

ii++;
var newname = "blood"+ii;
duplicateMovieClip(_root.blood,newname,i);
_root[newname]._x = this._x;
_root[newname]._y = this._y;
}
but it does not work any ideas why?

Duplicating
HI I'm having a problem duplicating and draging the problem is that when i drag movie clips they disapear how can i solve that?

the code is

Movie Clip

on (press) {
i = i + 1;
_root.cir.duplicateMovieClip ("cir2");
startDrag(this);
}
on(release){
stopDrag();
}


Thanks.

Duplicating Mcs Into Other Mcs
Hi,

I need to duplicate an mc but have it duplicate inside another mc, this is so i can scroll a list of dynamically created mcs. What do i need to change to the duplicateMovieClip code?

this is the original duplicate code that i used, it works absolutely fine but i need it to be embedded in another mc so i can use my scrollbar plug-in;

_root.basketcounter++;
duplicateMovieClip(_root.list_textfield, "list_textfield"+_root.basketcounter, _root.basketcounter);

And i want this list_textfield mc to be duplicated within the holder mc list_holder which will be at the root of the movie with list_textfield held inside it.

I tried this and changed the code but it didnt work, some help would be appreciated!! i tried this, to no luck;

_root.basketcounter++;
duplicateMovieClip(_root.list_holder.list_textfiel d, "list_textfield"+_root.basketcounter, _root.basketcounter);

its a git.

Steven.

Cheers.

Steven.

Duplicating Mc
hello,
is it possible to duplicate a movieclip created using createEmptyMovieClip?
cause i created an empty movieclip called sceneMC but wen i duplicate it nothing happens.
i put
_root.sceneMc.duplicateMovieClip("scene2",900);
but i cant see it. even if i move it around. Please help. Thank you.
oh yea the duplicated scene is going to ben on _root right? not inside sceneMc?

Duplicating MC
Hi, does somebody knows how to assign a set of loadVars object properties to a movie clip when itīs beign duplicated.
This is my code:


Code:

c = new LoadVars();
c.sendAndLoad("http://192.168.1.9/gmba/dbPassReturn.php",c,"POST");
c.onLoad = Create();
function Create(){
i=0;
while (i<=10) {
duplicateMovieClip (ref, "data"+i, i);
setProperty ("data"+i, _y, ref._y*i);
box=["data"+i];
name=["caption"+i];
[box].info.text = _root.c.[name]; //How to assign the changing value to a changing mc?, Thereīs something with the syntaxis.
i++;
}
}
Thnaks!

Help Duplicating MCs
Hi everybody,

I am trying to figure out a script to place duplicated MCs in a row, without space between copies. The problem is that when the MC is duplicated, each copy has different _width values, so I have been trying to calculate how to do this, but I haven't been able to find a solution. Could anyone help me with this?

Thanks a lot.


Code:
var initialX:Number = 325;
var initialY:Number = 73;
for (i = 1; i < 5; i++) {
var name:String = "tabButton" + i + "_mc";
var previousName:String = "tabButton" + (i - 1) + "_mc";
_root.tab_mc.duplicateMovieClip(name, i);
_root[name]._x = _root[previousName]._x + _root[previousName]._width;
_root[name]._y = _root.initialY;
}

Duplicating MC's To Get I/f
How can I duplicate a mc to generate an i/f like the blockbusters game? Its driving me mad. I can do something similer using the following code:

var counter = 0;
var even = 0;
var xvar = 0;
var yvar = 0;
do {
duplicateMovieClip(pol, ["pol"+counter], this.getNextHighestDepth());
if (counter%2 == 0) {
xvar = xvar+57.9;
yvar = yvar+31.1;
_root["pol"+counter]._x = xvar;
_root["pol"+counter]._y = yvar;
} else {
xvar = xvar+55.4;
yvar = yvar-31.1;
_root["pol"+counter]._x = xvar;
_root["pol"+counter]._y = yvar;
}
_root.pol._visible = 0;
_root["pol"+counter].onPress = function() {
_root.anim.gotoAndPlay(2);
};
_root.counter++;
trace(counter);
} while (counter<=5);

Any suggestions?

Duplicating
The below script is applyed to a submit button. It lets a user type in there txt click the sumbit button and it will then go on the stage where they can change the color and size and rotate. But at the moment if they click it once then change they color and stuff and they click it again for anotherm, one the original one dissapears how do i make it so when they click the submit button once it adds it and they can keep on adding more ?

Heres the script wat do i need to change:
on (release) {
//font = _root.extras.font_cb.getValue();
font = font_cb.getValue();
_global.text = input;

//if (_root.inputbox.text != "" ) {

count++;
duplicateMovieClip(_root.extras.textmovie,"textmov ie"+count,count+12);
this["textmovie"+count].onPress = function() {
this.startDrag();
this.dragging = true;

};
//End of the function
this["textmovie"+count].onRelease = function() {
stopDrag();
this.dragging = false;
};

//this["newmovie"+count].onPress = function() {
//tellTarget(_root) {
//txt = this["newmovie"+count] ;
//}
//};
if (font == "") {
_root.extras.textpopup._visible = true ;
} else if (font == "Arial") {
tellTarget ("_root.extras."+["textmovie"+count]){
gotoAndStop(1);
dtext.text = _global.text;
dtext.border = false;
dtext.background = false;
dtext.backgroundColor = 0xFFFFFF;
dtext.borderColor = 0x000000;
dtext.multiline = false;
dtext.wordWrap = false;
dtext.autoSize = "Left";
dtext.autoSize = "Right";
}
} else if (font == "Times") {
tellTarget ("_root.extras."+["textmovie"+count]){
gotoAndStop(2);
dtext.text = _global.text;
dtext.border = false;
dtext.background = false;
dtext.backgroundColor = 0xFFFFFF;
dtext.borderColor = 0x000000;
dtext.multiline = false;
dtext.wordWrap = false;
dtext.autoSize = "Left";
dtext.autoSize = "Right";
}
} else if (font == "Brush") {
tellTarget ("_root.extras."+["textmovie"+count]){
gotoAndStop(3);
dtext.text = _global.text;
dtext.border = false;
dtext.background = false;
dtext.backgroundColor = 0xFFFFFF;
dtext.borderColor = 0x000000;
dtext.multiline = false;
dtext.wordWrap = false;
dtext.autoSize = "Left";
dtext.autoSize = "Right";
}
} else if (font == "Comic Sans") {
tellTarget ("_root.extras."+["textmovie"+count]){
gotoAndStop(4);
dtext.text = _global.text;
dtext.border = false;
dtext.background = false;
dtext.backgroundColor = 0xFFFFFF;
dtext.borderColor = 0x000000;
dtext.multiline = false;
dtext.wordWrap = false;
dtext.autoSize = "Left";
dtext.autoSize = "Right";
}
}
//}
}

thanks

Duplicating MCs Help...
Hi all,
I'm trying to make a version of this:

http://education.smarttech.com/NR/rd...tionWallAU.gif

in flash. The basic idea is the user builds a wall of blocks which are made up of 1/2, 1/4 and 1/8 blocks- buttons inside movie clips. They then build the wall to make 1 (or a whole) on each row.

I've got them duplicating once, when I press a button, but when I press it again, the last duplicated clip (of either of the 3 blocks) disappears and the one I asked to duplicate appears as it should. I've got a :

i = i +1;
then duplicateMovieClip code so the depth should be going up.

Hmm.. any help would be greatly appreciated because it's doing my head in now.

Thanks

Duplicating Mc Through AS
Hi,
I want to mask a image with a movie clip which moves from top to down and duplicate this movie clip in such a way that when the first mc reaches the bottom of the stage another mc (duplicated) begins to play. (just like strip mask effect)

Can anyone help...

<li> Duplicating On Every Row
Hi,

I have a xml document with imformtion grouped as "slides" the text value of the slides are sometiems formatted with the <li> tag these then populate a textArea component. my problem is that as soon as I load a text with the <li> tag it duplicates on the all the rows... any one have a solution to that problem.?? I use CSS to format the text,

/Andreas

excample of the xml below, the bold text shouldn't get bullet points but it does...

<P class="OCHATEXT">Welcome to this section that looks at the terms and conditions for your job. <P class="OCHATEXT"></P><P class="OCHATEXT">There are three topics to complete in this section: </P><LI><A href="asfunction:_root.LinkSlide,67">Topic 1: Knowing your basic terms and conditions</A> <LI><A href="asfunction:_root.LinkSlide,50">Topic 2: What qualities are important for an OCHA member of staff?</A> <LI><A href="asfunction:_root.LinkSlide,59">Topic 3: Managing your professional development</A></LI></P><P class="OCHATEXT">edrghdshdshjsdjsj</P>

Duplicating Mc's
Hello, im making a simple animation of al ball bouncing.. using this code


Code:
import mx.transitions.Tween;
import mx.transitions.easing.*;

new Tween (mc,"_y".Bounce.easeOut,mc._y,473,5,true);
now this works perfect..

but is there a way to make 50 balls (mc's) with the same code...??? but not having to rename the instance name of every mc ??? because what i was doing is renaming the instance name of every mc and creating a new tween with the same code
new Tween (mc,"_y".Bounce.easeOut,mc._y,473,5,true); but changing the mc name of every one of my 50 mc's.. is there an easier way to do this..?? maybe some AS to just make 50 balls with the easing properties..

starting of the animation should look like this..

0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 and so on...

thanks alot.. i hope i made myself clear.

Duplicating
HI I'm having a problem duplicating and draging the problem is that when i drag movie clips they disapear how can i solve that?

the code is

Movie Clip

on (press) {
i = i + 1;
_root.cir.duplicateMovieClip ("cir2");
startDrag(this);
}
on(release){
stopDrag();
}


Thanks.

Duplicating Mcs Into Other Mcs
Hi,

I need to duplicate an mc but have it duplicate inside another mc, this is so i can scroll a list of dynamically created mcs. What do i need to change to the duplicateMovieClip code?

this is the original duplicate code that i used, it works absolutely fine but i need it to be embedded in another mc so i can use my scrollbar plug-in;

_root.basketcounter++;
duplicateMovieClip(_root.list_textfield, "list_textfield"+_root.basketcounter, _root.basketcounter);

And i want this list_textfield mc to be duplicated within the holder mc list_holder which will be at the root of the movie with list_textfield held inside it.

I tried this and changed the code but it didnt work, some help would be appreciated!! i tried this, to no luck;

_root.basketcounter++;
duplicateMovieClip(_root.list_holder.list_textfiel d, "list_textfield"+_root.basketcounter, _root.basketcounter);

its a git.

Steven.

Cheers.

Steven.

Duplicating Mc
hello,
is it possible to duplicate a movieclip created using createEmptyMovieClip?
cause i created an empty movieclip called sceneMC but wen i duplicate it nothing happens.
i put
_root.sceneMc.duplicateMovieClip("scene2",900);
but i cant see it. even if i move it around. Please help. Thank you.
oh yea the duplicated scene is going to ben on _root right? not inside sceneMc?

Duplicating MC
Hi, does somebody knows how to assign a set of loadVars object properties to a movie clip when itīs beign duplicated.
This is my code:


Code:

c = new LoadVars();
c.sendAndLoad("http://192.168.1.9/gmba/dbPassReturn.php",c,"POST");
c.onLoad = Create();
function Create(){
i=0;
while (i<=10) {
duplicateMovieClip (ref, "data"+i, i);
setProperty ("data"+i, _y, ref._y*i);
box=["data"+i];
name=["caption"+i];
[box].info.text = _root.c.[name]; //How to assign the changing value to a changing mc?, Thereīs something with the syntaxis.
i++;
}
}
Thnaks!

Help Duplicating MCs
Hi everybody,

I am trying to figure out a script to place duplicated MCs in a row, without space between copies. The problem is that when the MC is duplicated, each copy has different _width values, so I have been trying to calculate how to do this, but I haven't been able to find a solution. Could anyone help me with this?

Thanks a lot.


Code:
var initialX:Number = 325;
var initialY:Number = 73;
for (i = 1; i < 5; i++) {
var name:String = "tabButton" + i + "_mc";
var previousName:String = "tabButton" + (i - 1) + "_mc";
_root.tab_mc.duplicateMovieClip(name, i);
_root[name]._x = _root[previousName]._x + _root[previousName]._width;
_root[name]._y = _root.initialY;
}

Duplicating Just Once
I'm duplicating a mc from a button. What I need is to prevent it from duplicating again if the button is already pressed once. Some help?

Duplicating
I'm trying to make 'star' duplicate randomly from frame 0 to frame 75. VERY new to AS and studied a few tuts and found and adapted the following
dupMovie = function () {
for (i=0; i<2000; i++) {
star.duplicateMovieClip("star"+i, i, {_x:Math.random()*900, _y:Math.random()*900, _alpha:Math.random()*50});
with (eval("star"+i)) {
_xscale = _yscale=Math.random()*100;
}
}
};
dupMovie();
This creates a large number of stars instantly, but not progressively over 75 frames so I'm starting to understand what to ask for and how to ask it. Perhaps someone could help me along a bit. Next thing I need is to tell this script to execute over 75 frames. If someone could add to this and post it i could examine it and perhaps get on a bit further. Any takers
Wolfie

Copyright Đ 2005-08 www.BigResource.com, All rights reserved