FabGL
ESP32 VGA Controller and Graphics Library
|
Sprite * fabgl::CollisionDetector::updateAndDetectCollision | ( | Sprite * | sprite, |
bool | removeCollidingSprites = true |
||
) |
Update collision detector and detect collision with the specified sprite.
When a sprite changes its position or size it is necessary to update the collision detector. This method updates the detector and detects collisions.
sprite | The sprite to update and to check for collisions. |
removeCollidingSprites | If true the collided sprites are automatically removed from the collision detector. |