|
-
XRave
Resizing stuff HELP
Hello,
I was wondering what could I put into as the Actionscript IF i want a piece of MC to resize itself to 20% of its original size if I drag the MC into it? say I got 3 MCs called MC1, MC2, MC3 and the hittested MC "Shade", How could I put the AS?
Regards,
Tongxn
When you actually know what "OMG I have so much homework!" means, you won't want to be me.
Xrave
-
Hey tongxn,
Using those movieclips, this is how you would do it. Place the main movieclip onto the stage, the one you will be dragging the other movieclips into. Then place the hitTest movieclip shade onto it making sure its invisible 
Next place the following code on the other movieclips:
code:
on (press) {
this.startDrag();
}
on (release) {
this.stopDrag();
if (this.hitTest(_root.shade)) {
_root.mainMovieClip._xscale -= 20;
_root.mainMovieClip._yscale -= 20;
}
}
And that should do it
-
XRave
um, what is -= 20 here? Is it to make the MC to 20*20 size or 20%*20% of it's original size?
When you actually know what "OMG I have so much homework!" means, you won't want to be me.
Xrave
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|