Creadas las colisiones con los enemigos

This commit is contained in:
2022-07-11 14:18:30 +02:00
parent 4d41ef53f1
commit 4f6a99f670
14 changed files with 97 additions and 22 deletions

View File

@@ -292,4 +292,11 @@ void MovingSprite::switchRotate()
void MovingSprite::setFlip(SDL_RendererFlip flip)
{
mFlip = flip;
}
// Devuelve el rectangulo donde está el sprite
SDL_Rect MovingSprite::getRect()
{
SDL_Rect rect = {(int)getPosX(), (int)getPosY(), getWidth(), getHeight()};
return rect;
}