jeudi 2 juin 2016

how to create event listener to detect if a sprite bounding box is completely in side another sprite bounding box in cocos2dx?

I want an event listener to detect not just a collision, but to detect if a sprite bounding box is completely in side another sprite bounding box, I've used bool GameScene::onContactBegin(cocos2d::PhysicsContact &contact) returning false because I don't want any sort of collision physics but got only triggered on first contact. I want to use physics because its fast and accurate for my purposes. any ideas ??

enter image description here

Aucun commentaire:

Enregistrer un commentaire