JA VA! Nomes s'havia de fer les coses be i no ser un ansias

This commit is contained in:
2025-02-22 00:30:32 +01:00
parent f6098a479b
commit e361d295c1
39 changed files with 1053 additions and 1098 deletions

View File

@@ -12,6 +12,7 @@
#include "resource.h" // Para Resource
#include "room.h" // Para Room, tile_e
#include "texture.h" // Para Texture
#include "options.h"
// Constructor
Player::Player(player_t player)
@@ -23,7 +24,6 @@ Player::Player(player_t player)
this->input = player.input;
this->room = player.room;
this->debug = player.debug;
this->options = player.options;
// Crea objetos
sprite = new AnimatedSprite(renderer, resource->getAnimation(player.animation));
@@ -786,14 +786,14 @@ void Player::reLoadTexture()
// Recarga la paleta
void Player::reLoadPalette()
{
color = stringToColor(options->palette, "white");
if (options->cheat.infiniteLives)
color = stringToColor(options.palette, "white");
if (options.cheat.infiniteLives)
{
color = stringToColor(options->palette, "yellow");
color = stringToColor(options.palette, "yellow");
}
if (options->cheat.invincible)
if (options.cheat.invincible)
{
color = stringToColor(options->palette, "cyan");
color = stringToColor(options.palette, "cyan");
}
}