FabGL
ESP32 Display Controller and Graphics Library
|
void detectCollision | ( | Sprite * | sprite, |
CollisionDetectionCallback | callbackFunc, | ||
void * | callbackObj | ||
) |
Detects multiple collisions with the specified sprite.
It is necessary to call CollisionDetector.update() before detectCollision() so sprites position and size are correctly updated.
sprite | The sprite to detect collision. |
callbackFunc | The callback function called whenever a collision is detected. |
callbackObj | Pointer passed as parameter to the callback function. |
Definition at line 440 of file collisiondetector.cpp.