afegit define NO_AUDIO
renombrat define DEBUG a _DEBUG
This commit is contained in:
@@ -1,11 +1,12 @@
|
||||
#include "game.h"
|
||||
|
||||
#include <SDL3/SDL.h> // Para SDL_GetTicks, SDL_SetRenderTarget, SDL_EventType, SDL_CreateTexture, SDL_Delay, SDL_DestroyTexture, SDL_Event, SDL_GetRenderTarget, SDL_PollEvent, SDL_RenderTexture, SDL_SetTextureBlendMode, SDLK_1, SDLK_2, SDLK_3, SDLK_4, SDLK_5, SDLK_6, SDLK_7, SDLK_8, SDLK_9, SDL_BLENDMODE_BLEND, SDL_PixelFormat, SDL_Point, SDL_TextureAccess
|
||||
#include <algorithm> // Para max, find_if, clamp, find, min
|
||||
#include <array> // Para array
|
||||
#include <cstdlib> // Para rand, size_t
|
||||
#include <functional> // Para function
|
||||
#include <iterator> // Para distance, size
|
||||
#include <SDL3/SDL.h> // Para SDL_GetTicks, SDL_SetRenderTarget, SDL_EventType, SDL_CreateTexture, SDL_Delay, SDL_DestroyTexture, SDL_Event, SDL_GetRenderTarget, SDL_PollEvent, SDL_RenderTexture, SDL_SetTextureBlendMode, SDLK_1, SDLK_2, SDLK_3, SDLK_4, SDLK_5, SDLK_6, SDLK_7, SDLK_8, SDLK_9, SDL_BLENDMODE_BLEND, SDL_PixelFormat, SDL_Point, SDL_TextureAccess
|
||||
|
||||
#include <algorithm> // Para max, find_if, clamp, find, min
|
||||
#include <array> // Para array
|
||||
#include <cstdlib> // Para rand, size_t
|
||||
#include <functional> // Para function
|
||||
#include <iterator> // Para distance, size
|
||||
|
||||
#include "asset.h" // Para Asset
|
||||
#include "audio.h" // Para Audio
|
||||
@@ -88,7 +89,7 @@ Game::Game(int player_id, int current_stage, bool demo)
|
||||
initPaths();
|
||||
setTotalPower();
|
||||
|
||||
#ifdef DEBUG
|
||||
#ifdef _DEBUG
|
||||
// Si se empieza en una fase que no es la primera
|
||||
if (!demo_.enabled) {
|
||||
for (int i = 0; i < Stage::number; ++i) {
|
||||
@@ -1120,7 +1121,7 @@ void Game::checkEvents() {
|
||||
break;
|
||||
}
|
||||
|
||||
#ifdef DEBUG
|
||||
#ifdef _DEBUG
|
||||
checkDebugEvents(event);
|
||||
#endif
|
||||
GlobalEvents::check(event);
|
||||
@@ -1685,7 +1686,7 @@ void Game::updateGameStateShowingGetReadyMessage() {
|
||||
|
||||
// Actualiza las variables durante el transcurso normal del juego
|
||||
void Game::updateGameStatePlaying() {
|
||||
#ifdef DEBUG
|
||||
#ifdef _DEBUG
|
||||
if (auto_pop_balloons_) {
|
||||
Stage::addPower(5);
|
||||
}
|
||||
@@ -1818,7 +1819,7 @@ void Game::checkServiceMenu() {
|
||||
service_menu_was_active_ = service_menu_is_active;
|
||||
}
|
||||
|
||||
#ifdef DEBUG
|
||||
#ifdef _DEBUG
|
||||
// Comprueba los eventos en el modo DEBUG
|
||||
void Game::checkDebugEvents(const SDL_Event &event) {
|
||||
if (event.type == SDL_EVENT_KEY_DOWN && static_cast<int>(event.key.repeat) == 0) {
|
||||
|
||||
Reference in New Issue
Block a user