Home Tutorials Forums Articles Blogs Movies Library Employment Press
Old 11-11-2006, 01:04 AM   #1
Registered User
Join Date: Nov 2006
Posts: 2
Default array of movie clips

Im still a beginner.
I want to crate an array of 12 different movie clips. and have the current clip fade in on the press of corresponding button in seperate movie clip.
While that fades in I want to fade out the previous clip that was showing. Here is what I think the code would look like but It doesnt work any tips?

var allclips:Array = [mc1, mc2, mc3, mc4, mc4, etc];
onEnterFrame = function() {
if (previousclip._alpha > 0) {previousclip._alpha -= 10}
if (currentclip._alpha < 100) {currentclip._alpha += 10}
btn1.onpress = function() {
previousclip = allclips
mc1 = currentclip};
question 2:
I would also like to make the movie clips not visible if the alpha is 0 because there are buttons in each movie clip.
Would I insert this code into the onEnterFrame?
if (previousclip._alpha = 0) {previousclip._visible = false}
if (previousclip._alpha > 0) {previousclip._visible = true} (

Last edited by littlec; 11-12-2006 at 03:57 AM. Reason: code correction
littlec is offline   Reply With Quote
Old 11-11-2006, 01:28 AM   #2
Senior Member
Join Date: Jan 2004
Posts: 279

There are many ways of doing that. Here is a sample of a pretty simple method.
Attached Files
File Type: zip sample.fla.zip (5.7 KB, 145 views)
wu-tang is offline   Reply With Quote
Old 11-11-2006, 03:47 AM   #3
Registered User
Join Date: Nov 2006
Posts: 2
Default thank you

thanks for the quick reply. How would I go about doing the same thing but with each movie clip having its own button? Btn1 affects mc1, btn2 affects mc2, etc...

edit: It need it to be able to change in a random order instead of sequential.

Last edited by littlec; 11-11-2006 at 03:48 AM. Reason: more detail
littlec is offline   Reply With Quote

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Movie Clips within Movie Clips: Text link problem Inquirer Flash 8 General Questions 0 12-24-2005 12:12 AM
Loading images in different frames.. nchagial ActionScript 2.0 22 12-21-2005 09:06 AM
How can I load multiple movie clips and mp3 so that the swf file will work? wlester ActionScript 2.0 0 09-16-2005 09:01 AM
Dynamic Movie Clips within Dynamic Movie Clips Vez ActionScript 2.0 2 09-30-2004 10:37 AM
Movie Clips Order Luigi Vercotti ActionScript 1.0 (and below) 2 02-27-2004 11:32 AM

All times are GMT. The time now is 04:51 AM.

Follow actionscriptorg on Twitter


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2015, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2013 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.