I want to stop all actions of the sprite which are seeing on screen at any point of time…
All My sprites are add in CCSpriteBatchNode.
Usually i search on my array (witch contains all my sprites) to check if position is inside my window size boundaries. I dont think there is a method to check if the is sprite is visible on screen. But i could be wrong. The (wrost?) and most simple solution (i use!) is something like this (pseudo code ahead):
for(sprite in my spriteArray) {
if(sprite.position.x+sprite.contentsize.width > 0 && sprite.position.x+sprite.contentsize.width < windowSize.width) {
if(sprite.position.y+sprite.contentsize.height > 0 && sprite.position.y+sprite.contentsize.height < windowSize.height) {
//sprite is fully visible in view
}
}
}