flash动作详解。

来源:百度知道 编辑:UC知道 时间:2024/06/20 07:58:03
var drag = 1.000000E-001;
var flex = 7.000000E-001;
var menuEN = new Array("default");
var menuZH = new Array("网站首页");
var menuURL = new Array("default.asp");
var menuColor = new Array(14158008);
var mBlock = this.attachMovie("mblock", "mb", 0);
mBlock._y = 5;
mBlock.goalX = -100;
mBlock.onEnterFrame = function ()
{this.Step = this.Step * flex + (this.goalX - this.px) * drag;
this.px = this.px + this.Step;
this._x = this.px;
if (this.sOut && this._xscale < 9.950000E+001)
{this._xscale = this._xscale + (100 - this._xscale) / 8;
} // end if
if (this.sIn && this._xscale > 1.000000E-001)
{this._xscale = this._xscale + -this._xscale / 8;
} // end if
};
var MBColor = new Color(mBlock);
var i = 0;
while (i < menuZH.length)
{var theItem = this.attachMovie("MenuItem", "Item&quo

插入就是点你要插入的东西(如帧、组件等)。
大致意思是:
var阻力= 1.000000E-001;
var导电线= 7.000000E-001;
var menuEN =新的列阵(“缺省”);
var menuZH =新的列阵(“网站首页");
var menuURL =新的列阵(“default.asp”);
var menuColor =新的列阵(14158008);
var mBlock = this.attachMovie (“mblock”, “兆位”, 0);
mBlock. _y = 5;
mBlock.goalX = -100;
mBlock.onEnterFrame =作用()
{这。步=这。步*导电线+ (this.goalX - this.px) *阻力;
this.px = this.px +这。步;
this. _x = this.px;
if (this.sOut &&这。_xscale < 9.950000E+001)
{这。_xscale =这。_xscale + (100 -这。_xscale)/8;
} //末端,如果
if (this.sIn &&这。_xscale > 1.000000E-001)
{这。_xscale =这。_xscale + -这。_xscale/8;
} //末端,如果
};
var MBColor =新的颜色(mBlock);
var我= 0;
while (i < menuZH.length)
{var theItem = this.attachMovie (“MenuItem”, “项目” + i, i + 10);
theItem. _x = i * 84;
theItem.mColor = menuColor [i];
theItem.URL = menuURL [i];
theItem.mc_ZH.itext.text