Añadiendo la estructura param

This commit is contained in:
2024-06-18 07:21:46 +02:00
parent c10de5e929
commit cb3eb7855e
3 changed files with 7 additions and 7 deletions

View File

@@ -1682,7 +1682,7 @@ void Game::renderDeathFade(int counter)
{
rect[i].x = 0;
rect[i].y = i * 16;
rect[i].w = GAMECANVAS_WIDTH;
rect[i].w = param->gameWidth;
if (i == 0)
{
rect[i].h = h;
@@ -1696,7 +1696,7 @@ void Game::renderDeathFade(int counter)
}
else
{
SDL_Rect rect = {0, 0, GAMECANVAS_WIDTH, GAMECANVAS_HEIGHT};
SDL_Rect rect = {0, 0, param->gameWidth, param->gameHeight};
SDL_RenderFillRect(renderer, &rect);
}
}
@@ -2421,7 +2421,7 @@ void Game::throwCoffee(int x, int y)
ss->setAccelX(0.0f);
ss->setAccelY(0.2f);
ss->setDestX(x + (ss->getVelX() * 50));
ss->setDestY(GAMECANVAS_HEIGHT + 1);
ss->setDestY(param->gameHeight + 1);
ss->setEnabled(true);
ss->setEnabledCounter(1);
ss->setSpriteClip(0, 0, 16, 16);