From 142603db711dbc0091cfe71f2bae8c7a5f3973fe Mon Sep 17 00:00:00 2001 From: Sergio Valor Date: Sun, 17 Aug 2025 08:08:48 +0200 Subject: [PATCH] hi_score_table: faltava posar el fondo en modo manual game: redefinides les prioritats de dibuixat -> jugadors altra volta al front --- data/config/param_320x256.txt | 4 ++-- source/director.cpp | 2 +- source/sections/game.cpp | 8 +++++--- source/sections/hiscore_table.cpp | 2 +- 4 files changed, 9 insertions(+), 7 deletions(-) diff --git a/data/config/param_320x256.txt b/data/config/param_320x256.txt index 5b3d6c9..cf2934b 100644 --- a/data/config/param_320x256.txt +++ b/data/config/param_320x256.txt @@ -84,8 +84,8 @@ service_menu.window_message.title_color 6496C8FF # Color del tít service_menu.window_message.text_color DCDCDCFF # Color del texto en ventanas de mensaje (RGBA hexadecimal) service_menu.window_message.padding 15.0f # Espaciado interno de ventanas de mensaje (píxeles) service_menu.window_message.line_spacing 5.0f # Espaciado entre líneas de texto (píxeles) -service_menu.window_message.title_separator_spacing 10.0f # Espaciado entre título y contenido (píxeles) -service_menu.window_message.min_width 250.0f # Ancho mínimo de ventanas de mensaje (píxeles) +service_menu.window_message.title_separator_spacing 20.0f # Espaciado entre título y contenido (píxeles) +service_menu.window_message.min_width 200.0f # Ancho mínimo de ventanas de mensaje (píxeles) service_menu.window_message.min_height 32.0f # Alto mínimo de ventanas de mensaje (píxeles) service_menu.window_message.max_width_ratio 0.8f # Ratio máximo de ancho respecto a pantalla (0.0-1.0) service_menu.window_message.max_height_ratio 0.8f # Ratio máximo de alto respecto a pantalla (0.0-1.0) diff --git a/source/director.cpp b/source/director.cpp index ebd1142..180287c 100644 --- a/source/director.cpp +++ b/source/director.cpp @@ -41,7 +41,7 @@ Director::Director(int argc, std::span argv) { Section::name = Section::Name::GAME; Section::options = Section::Options::GAME_PLAY_1P; #elif _DEBUG - Section::name = Section::Name::LOGO; + Section::name = Section::Name::GAME; Section::options = Section::Options::GAME_PLAY_1P; #else // NORMAL GAME Section::name = Section::Name::LOGO; diff --git a/source/sections/game.cpp b/source/sections/game.cpp index 9268b10..edbadbd 100644 --- a/source/sections/game.cpp +++ b/source/sections/game.cpp @@ -986,12 +986,14 @@ void Game::fillCanvas() { // Dibuja los objetos background_->render(); - renderPlayers(); - renderSmartSprites(); - renderItems(); + balloon_manager_->render(); + renderSmartSprites(); // El cafe que sale cuando te golpean + renderItems(); tabe_->render(); renderBullets(); + renderPlayers(); + renderPathSprites(); // Deja el renderizador apuntando donde estaba diff --git a/source/sections/hiscore_table.cpp b/source/sections/hiscore_table.cpp index eb9660b..2db6f79 100644 --- a/source/sections/hiscore_table.cpp +++ b/source/sections/hiscore_table.cpp @@ -33,7 +33,6 @@ HiScoreTable::HiScoreTable() backbuffer_(SDL_CreateTexture(renderer_, SDL_PIXELFORMAT_RGBA8888, SDL_TEXTUREACCESS_TARGET, param.game.width, param.game.height)), fade_(std::make_unique()), background_(std::make_unique()), - ticks_(0), view_area_(SDL_FRect{0, 0, param.game.width, param.game.height}), fade_mode_(Fade::Mode::IN), @@ -280,6 +279,7 @@ void HiScoreTable::initFade() { // Inicializa el fondo void HiScoreTable::initBackground() { + background_->setManualMode(true); background_->setPos(param.game.game_area.rect); background_->setCloudsSpeed(-0.1F);