此问题我已解决了,无需帮助了
单击影片剪辑的按钮,为何显示主时间轴的totalFrames,currentFrame未定义
60var inc:Number = 0;
prevBtn.addEventListener(MouseEvent.CLICK, preprog);
function preprog(event:MouseEvent):void
{
if (root.currentFrame == 1) {
gotoAndStop(1);
} else {
inc = root.currentFrame-1;
gotoAndStop(inc);
}
}
nextBtn.addEventListener(MouseEvent.CLICK, nextprog);
function nextprog(event:MouseEvent):void
{
if (root.currentFrame == root.totalFrames) {
gotoAndStop(root.totalFrames);
} else {
inc = root.currentFrame+1;
gotoAndStop(inc);
}
}
舞台上有8张图片,通过单击舞台上的影片剪辑按钮,播放主时间轴的图片。
- 点赞
- 收藏
- 复制链接分享
3条回答
为你推荐
- PHP图像缩放 - 指数刻度
- math
- image
- php
- zoom
- 1个回答