Añadiendo habitaciones

This commit is contained in:
2022-11-12 10:00:27 +01:00
parent 763126580f
commit 6b4c089683
21 changed files with 302 additions and 128 deletions

View File

@@ -18,15 +18,7 @@ Player::Player(player_t player)
sprite = new AnimatedSprite(renderer, resource->getAnimation(player.animation));
// Inicializa variables
color = stringToColor(options->palette, "white");
if (options->cheat.infiniteLives)
{
color = stringToColor(options->palette, "yellow");
}
if (options->cheat.invincible)
{
color = stringToColor(options->palette, "cyan");
}
reLoadPalette();
onBorder = false;
border = BORDER_TOP;
autoMovement = false;
@@ -708,6 +700,14 @@ void Player::reLoadTexture()
void Player::reLoadPalette()
{
color = stringToColor(options->palette, "white");
if (options->cheat.infiniteLives)
{
color = stringToColor(options->palette, "yellow");
}
if (options->cheat.invincible)
{
color = stringToColor(options->palette, "cyan");
}
}
// Establece el valor de la variable