0
如何使用getTimer()
正确执行类似sleep
函数?我需要每15秒做一次动作。下面的代码不起作用。我在Linux上用mtasc
编译器编译它。使用getTimer()方法睡眠脚本2
class Tuto
{
static var lastMsg = 0;
static var msgInt = 15000;
static function main(mc)
{
if(getTimer() > lastMsg + msgInt)
{
trace("something");
lastMsg = getTimer();
}
}
}