Home Tutorials Forums Articles Blogs Movies Library Employment Press Buy templates

Go Back   ActionScript.org Forums > ActionScript Forums Group > ActionScript 1.0 (and below)

Reply
 
Thread Tools Rate Thread Display Modes
Old 03-07-2007, 08:42 PM   #1
ssipse
Registered User
 
Join Date: Feb 2003
Posts: 222
Default function reset question

I'm using this function to fade out some movie clips on press

Code:
function community() {
	community = new Array(1, 2, 3, 6, 9, 11, 13, 16, 7);
	for (z=0; z<community.length; ++z) {
		i = community[z];
		_root.cylinder["cylinder_small"+i].fadeout(30);
	}
}

on(press){ community()}
It works fine but when movie clips are set back to _alpha 100 and I press that function again, and it doesnt work. It only works first time. Why?
ssipse is offline   Reply With Quote
Old 03-07-2007, 08:44 PM   #2
senocular
six eyes
 
senocular's Avatar
 
Join Date: Jan 2003
Location: San Francisco, CA (USA)
Posts: 7,758
Send a message via ICQ to senocular Send a message via AIM to senocular Send a message via MSN to senocular Send a message via Yahoo to senocular
Default

that all depends what fadeout is.
__________________
(6)
senocular is offline   Reply With Quote
Old 03-07-2007, 08:47 PM   #3
ssipse
Registered User
 
Join Date: Feb 2003
Posts: 222
Default

This is code im using to fade out

Code:
MovieClip.prototype.fadeout = function(goalalpha) {
	this.onEnterFrame = function() {
		if (this._alpha>=goalalpha) {
			this._alpha -= _global.speed;
		} else {
			delete this.onEnterFrame;
		}
	};
};
ssipse is offline   Reply With Quote
Old 03-07-2007, 10:06 PM   #4
ssipse
Registered User
 
Join Date: Feb 2003
Posts: 222
Default

help needed asap
ssipse is offline   Reply With Quote
Reply


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
Dynamic function question nate63179 ActionScript 2.0 2 03-28-2006 12:09 AM
2 primitive numbers not showing up as equal when returned from OOP functions arianhojat ActionScript 2.0 12 03-14-2006 08:37 PM
Question about a function playing sounds scanman20 ActionScript 2.0 10 01-24-2006 04:53 AM
Need help making this run faster MAYAaddict ActionScript 2.0 3 11-17-2005 11:09 PM
tweenining with AS lelales ActionScript 2.0 5 04-26-2005 11:05 PM


All times are GMT. The time now is 02:13 AM.


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