This works, but it's not really doing anything specific to AS2.0.
MovieClip.prototype.mcbounceload = function()
{
this.bounce = 0.4;
this.speed = 0.9;
this.x = this.xpos = this._x;
this.y = this.ypos = this._y;
};
MovieClip.prototype.mcbounceenter = function()
{
this.x = (this.x * this.bounce) + ((this.xpos - this._x) *
this.speed);
this.y = (this.y * this.bounce) + ((this.ypos - this._y) *
this.speed);
this._x += this.x;
this._y += this.y;
};
mc.mcbounceload ();
mc.onEnterFrame = function()
{
this.xpos = _xmouse;
this.ypos = _ymouse;
this.mcbounceenter();
}
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of coker todd
Sent: Thursday, August 16, 2007 8:15 PM
To: [email protected]
Subject: RE: [Flashcoders] porting to Flash 8
so the new code reads:
MovieClip.prototype.mcbounceload = function () {
bounce = 0.4;
speed = 0.9;
xpos = _x;
ypos = _y;
};
MovieClip.prototype.mcbounceenter = function () {
x = x*bounce+(xpos-_x)*speed;
_x += x;
y = y*bounce+(ypos-_y)*speed;
_y += y;
};
on each MC this is the code:
onClipEvent (load) {
mcfedernload();
}
onClipEvent (enterFrame) {
mcfedernenter();
}
code on each button:
on (release) {
_parent.mc2.xpos = 26;
_parent.mc2.ypos = 247;
_parent.mc3.xpos = 26;
_parent.mc3.ypos = 267;
_parent.mc4.xpos = 26;
_parent.mc4.ypos = 287;
_parent.mc5.xpos = 26;
_parent.mc5.ypos = 307;
Does this help??
_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com