Terminating app due to uncaught exception of class '_NSZombie_NSException'

今天写程序的时候遇到这个问题

  1. Assertion failure in -[CCTouchDispatcher forceAddHandler:array:], /Users/thomaszhu/Desktop/works/startGameParam/myTankDemo/libs/cocos2d/Platforms/iOS/CCTouchDispatcher.m:88
  2. Terminating app due to uncaught exception of class '_NSZombie_NSException'    
  3.  libc++abi.dylib: terminate called throwing an exception
是cocos2d游戏中,原来的层中   self.isTouchEnabled = YES; 但是在原来的层上面加载的这个层要求self.isTouchEnabled = NO;

当这个层也能用完之后,你必需在这个层中将self.isTouchEnabled 设为 YES;至于在什么地方将其设为YES,就要看你的程序是怎么写了

我是用了if,else语句,if(这个层要用完了){self.isTouchEnabled = YES;}


希望能帮到大家吧

你可能感兴趣的:(Terminating app due to uncaught exception of class '_NSZombie_NSException')