objc[989] objc_exception_throw failed
I was just adding some more CCSprites to a CCLayer and it just starts crashing giving me the error: objc[989] objc_exception_throw failed. Is there like a limit to the amount of CCSprites you can have on a screen or something? I added the CCSprites doing the following with the CCSprites already declared at interface:
L1Circle1 = [CCSprite spriteWithFile:@"LaserCircle.png"];
[L1Circle1 setPosition:ccp(180开发者_Go百科,180)];
[self addChild:L1Circle1];
What am I doing wrong?
Oh, silly me. I fixed it. I forgot to put "LaserCircle.png" in my resources. So forgetting to put pictures in your resources causes that.
EXTENSION: I found getting errors like these most likely mean you don't have that resource or selector... You can find the specific problem just by scrolling up a bit in the Output Log and it will tell where the problem occurred.
精彩评论