安卓打包报这个错误
jsb: ERROR: File /Users/bona/Desktop/trunk1/quxueshijie/frameworks/runtime-src/proj.android/…/…/cocos2d-x/cocos/scripting/js-bindings/proj.android/…/auto/jsb_cocos2dx_studio_auto.cpp: Line: 12148, Function: js_cocos2dx_studio_ActionTimeline_getCurrentFrame
代码如下:
var yqdmxSpt=cc.Layer.extend({
ctor: function () {
this._super();
this.sourse=ccs.load(res.yqdmx_animationNode);
this.Node=this.sourse.node;
this.addChild(this.Node);
this.ac=this.sourse.action;
return true;
},
idile: function () {
this.Node.stopAllActions();
//this.ac.gotoFrameAndPlay(0,20,0,true);
this.ac.play("daiji",true);
this.Node.runAction(this.ac);
},
success: function () {
this.Node.stopAllActions();
//this.ac.gotoFrameAndPlay(26,66,0,true);
this.ac.play("chenggong",false);
this.Node.runAction(this.ac);
},
fail: function () {
this.Node.stopAllActions();
//this.ac.gotoFrameAndPlay(67,122,0,true);
this.ac.play("shibai",false);
this.Node.runAction(this.ac);
}
});
在调用时
在ctor加载
this._sptplane=new yqdmxSpt();
this.addChild(this._sptplane);
this._sptplane.idile();
这个动画可以执行,但是如果我在button 的会掉里边执行失败的动作的时候,在安卓上就会报错,但浏览器是不会报错的
stoneBtn.addClickEventListener(this.selectedAnsewr.bind(this));
selectedAnsewr:function()
{
//这个就报上边那个错去
this._sptplane.fail();
}