elimina DEBUG_PAUSE: era una eina puntual de captures

This commit is contained in:
2026-05-16 23:25:40 +02:00
parent f10be8c277
commit 169a5ea7aa
4 changed files with 3 additions and 27 deletions
+1 -22
View File
@@ -63,11 +63,7 @@ Game::Game(int num_players, int current_stage, SDL_Renderer *renderer, bool demo
// Pasa variables
this->demo_.enabled = demo;
this->num_players_ = num_players;
#ifdef DEBUG_PAUSE
this->current_stage_ = 3;
#else
this->current_stage_ = current_stage;
#endif
if (num_players == 1) { // Si solo juega un jugador, permite jugar tanto con teclado como con mando
player_one_control_ = Options::inputs[0].device_type;
Options::inputs[0].device_type = Input::Device::ANY;
@@ -106,9 +102,6 @@ Game::Game(int num_players, int current_stage, SDL_Renderer *renderer, bool demo
// Inicializa las variables necesarias para la sección 'Game'
init();
#ifdef DEBUG_PAUSE
pause = false;
#endif
}
Game::~Game() {
@@ -270,8 +263,7 @@ void Game::init() {
balloons_popped_ += stage_[i].power_to_complete;
}
total_power_to_complete_game_ = std::accumulate(std::begin(stage_), std::end(stage_), 0,
[](int acc, const auto &s) { return acc + s.power_to_complete; });
total_power_to_complete_game_ = std::accumulate(std::begin(stage_), std::end(stage_), 0, [](int acc, const auto &s) { return acc + s.power_to_complete; });
// Modo demo
demo_.recording = false;
@@ -2730,13 +2722,8 @@ void Game::iterate() {
}
}
#ifdef DEBUG_PAUSE
if (!pause)
update();
#else
// Actualiza la lógica del juego
update();
#endif
// Dibuja los objetos
render();
@@ -2759,14 +2746,6 @@ void Game::handleEvent(const SDL_Event *event) {
}
}
#ifdef DEBUG_PAUSE
if (event->type == SDL_EVENT_KEY_DOWN) {
if (event->key.scancode == SDL_SCANCODE_P) {
pause = !pause;
}
}
#endif
// Eventos específicos de la pantalla de game over
if (section_->subsection == SUBSECTION_GAME_GAMEOVER) {
if (event->type == SDL_EVENT_KEY_DOWN && static_cast<int>(event->key.repeat) == 0) {