今日出包测试遇到一个崩溃问题,调试发现崩溃的java调lua的代码里了,查看lua代码,有openGl绘制工作,因此尝试应用解决方法
instance.runOnUiThread(new Runnable() { public void run() { //调用lua接口在此调用 } });
重新出包后还是会出现崩溃,于是又用
Cocos2dxGLSurfaceView.getInstance().queueEvent(new Runnable() { @Override public void run() { //调用lua的代码写在这里 } });
然后测试,发现解决问题啦,原谅我还是个小白,他们的区别在哪里还请百度!