I am trying to do collision detection between a rectangle and a circle. I came up with this method:
-(BOOL) isCollidingRect:(CCSprite *) spriteOne WithSphere:(CC
You can use CGRectIntersectsRect to achieve this.
-(BOOL) isCollidingRect:(CCSprite *) spriteOne WithSphere:(CCSprite *) spriteTwo { return CGRectIntersectsRect([spriteOne boundingBox],[spriteTwo boundingBox]); }
It is not pixel perfect but as i understand that is not necessary in this case.