Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

I made this: www.byngdesigns.co. 5

Status
Not open for further replies.

BigBadDave

Programmer
May 31, 2001
1,069
EU
I made this:

Regards
David Byng
spider.gif

davidbyng@hotmail.com
 
Really cool one David!!!
I will sure take it to study the code! Regards,
Dragos.


 
could you send me the ActionScript? I don't have Flash here and would love to see the code.

A star for offering this to people. Gary Haran
 
This is the main functions:

Code:
var total = 5;
var speed = 4;
function menuC () {
	for (var i = 0; i<total+1; i++) {
		_root[&quot;but&quot;+i].newY = _root[&quot;but&quot;+i].origY;
	}
}
function menuO (clip) {
	for (var i = 0; i<total+1; i++) {
		if (_root[&quot;but&quot;+i] == clip) {
			for (var x = (i+1); x<total+1; x++) {
				_root[&quot;but&quot;+x].newY += clip.openA;
			}
		}
	}
}

then on each button:

Code:
onClipEvent (load) {
	title = &quot;> TXT&quot;;
	var origY = _y;
	var newY = origY;
    var openA = 50;
}
onClipEvent (enterFrame) {
	_y += (newY-_y)/_root.speed;
}

and the button code:

Code:
on (press) {
	_root.menuC();
	_root.menuO(this);
}
Regards
David Byng
spider.gif

davidbyng@hotmail.com
 
BidBadDave:

Great help! I am relatively new to Studio MX -- would you happen to have any more tutorials on your site?

Many, many thanks!!

Here's a star for you!!
 
Dave you rock! :) I'd give you two stars if I could! :) Your code is nice and clean two (from a JavaScript/ECMAScript coder). Gary Haran
 
Nice work, man.
 
David!
This morning the links are not working... Regards,
Dragos.


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top