【发布时间】:2013-10-05 11:27:54
【问题描述】:
对于某些人来说,这确实是一个容易回答的问题,呵呵:如何在每次进入特定帧时将变量值增加 1?
我目前有这段代码运行一次,下次时间轴在帧上时它不会再次运行:
// This is at the end of the animation
var DAY = 0;
DAY++;
dayTextField.text = DAY;
gotoAndStop(7); // Go to the beginning and re-loop the animation
我尝试在从stage.addEventListener(Event.ENTER_FRAME, function) 运行的函数中执行此代码,但这只会一遍又一遍地不断增加值。
谢谢。
【问题讨论】:
标签: actionscript-3 flash flash-cs6