使用了源码里类似的方式来继承cc.RepeatForever,为嘛step函数不能被调用
var LotteryAction = cc.RepeatForever.extend({
moveTo: ...,
rotateBy: ...,
ctor: function () {
cc.RepeatForever.prototype.ctor.call(this, cc.spawn(this.moveTo, this.rotateBy));
},
step: function (dt) {
cc.log('step');
...
},
});
从头至尾都没看到step输出过,这是何解,不能重写step么