flash命令求解

来源:百度知道 编辑:UC知道 时间:2024/05/12 14:06:04
翻译一下内容,TXTR2为文字图片

var speed = 1;
btn_down.onRollOver = function() {
onEnterFrame = function () {
if (txtR2._y>150-txtR2._height) {
txtR2._y -= speed;
}
};
};
btn_down.onRollOut = btn_down.onDragOut=function () {
delete onEnterFrame;
};
btn_up.onRollOver = function() {
onEnterFrame = function () {
if (txtR2._y<5) {
txtR2._y += speed;
}
};
};
btn_up.onRollOut = btn_up.onDragOut=function () {
delete onEnterFrame;
};
btn_down.onPress = btn_up.onPress=function () {
speed = 10;
};
btn_down.onRelease = btn_down.onReleaseOutside=btn_up.onRelease=btn_up.onReleaseOutside=function () {
speed = 1;
};
btn_close.onPress = function() {
_parent._parent.xiangxi._visible = true;
_parent.gotoAndPlay(2);
this.enabled = false;
};
//鼠标滚轮:
mouseListener = new Object();
mouseListener.onMouseWheel = fu

var speed = 1;
//变量speed,方便以后修改速率;
btn_down.onRollOver = function() {
//设置一个函数,该函数在鼠标经过时执行;
onEnterFrame = function () {
//以帧频率执行以下函数
if (txtR2._y>150-txtR2._height) {
当txtr2的纵坐标大于150减它的高度值时
txtR2._y -= speed; txtr2以speed的速度匀速下降
}
};
};
btn_down.onRollOut = btn_down.onDragOut=function () {
当鼠标移出该按钮时或者拖动出该按钮时,执行下列函数
delete onEnterFrame; 停止onEnterFrame事件
};
btn_up.onRollOver = function() { 当鼠标经过另个按钮btn_up时执行
onEnterFrame = function () { 以帧速率不断激活
if (txtR2._y<5) { 假如txtr2的纵坐标值小于5时执行
txtR2._y += speed; 让它向上运动
}
};
};
btn_up.onRollOut = btn_up.onDragOut=function () {
让up按钮鼠标移出或拖拽出时删除onEnterFrame事件
delete onEnterFrame;
};
btn_down.onPress = btn_up.onPress=function () {
按钮down和up按下时
speed = 10; 速度=10
};
btn_down.onRelease = btn_down.onReleaseOutside=btn_up.onRelease=btn_up.onReleaseOutside=function () {
spee