编译Cocos2dx时,在EAGLView.mm中
代码:
for (UITouch *touch in touches) {
ids[i] = (uintptr_t)touch;//(int)touch;//在这里int会出错,将其改为uintptr_t即可通过
xs[i] = [touch locationInView: [touch view]].x * view.contentScaleFactor;;
ys[i] = [touch locationInView: [touch view]].y * view.contentScaleFactor;;
++i;
}