EDIT:
NSLog(@"%@",currentBombs); //Here doesn't, guessing crash is at ^
Your %@ implies NSString
. currentBombs is likely an int. Try
NSLog(@"%i",currentBombs); //Here doesn't, guessing crash is at ^
CCSprite
requires a texture. You can (maybe?) have a CCSprite
without one, but that's not what CCSprite
is for.
You will want to use CCNode
for this purpose:
CCNode* node = [CCNode new];
This is a full-fledged Cocos2d object that you can move, etc. You'd add your Bomb to it, and move the CCNode around, like this:
Bomb *myBomb = [Bomb new]; //or whatever
CCNode* bombNode = [CCNode new];
//add the bomb to the node
[bombNode addChild:myBomb];
//move the node
bombNode.position = CGPointMake(10, 20)
This allows you to remove the myBomb
from your node, effectively having something that you can add whatever you want without needing to display anything, but when you want to, it can be done easily.
Good luck