From cbdc7d9fc3f43c3d68fb5eaf7a436cbe1c0810f2 Mon Sep 17 00:00:00 2001 From: Sergio Valor Date: Tue, 30 Aug 2022 16:45:26 +0200 Subject: [PATCH] =?UTF-8?q?Clase=20screen=20actualizada=20a=20la=20=C3=BAl?= =?UTF-8?q?tima=20versi=C3=B3n?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- source/director.cpp | 6 +++--- source/game.cpp | 3 --- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/source/director.cpp b/source/director.cpp index 99a6a24..5a0064d 100644 --- a/source/director.cpp +++ b/source/director.cpp @@ -24,7 +24,7 @@ Director::Director(std::string path) // Crea el puntero a la estructura y carga el fichero de configuración options = new options_t; options->fullScreenMode = 0; - options->windowSize = 2; + options->windowSize = 3; options->filter = FILTER_NEAREST; options->vSync = true; options->screenWidth = GAMECANVAS_WIDTH * options->windowSize; @@ -201,7 +201,7 @@ Uint8 Director::getSection() // Establece el valor de la variable void Director::setSection(section_t section) { - section = section; + this->section = section; } void Director::runLogo() @@ -226,7 +226,7 @@ void Director::runGame() void Director::run() { // Bucle principal - while (!(getSection() == SECTION_PROG_QUIT)) + while (getSection() != SECTION_PROG_QUIT) { switch (getSection()) { diff --git a/source/game.cpp b/source/game.cpp index 8512619..3bcd7d9 100644 --- a/source/game.cpp +++ b/source/game.cpp @@ -37,9 +37,6 @@ Game::~Game() input = nullptr; // Libera la memoria de los objetos - delete screen; - screen = nullptr; - delete itemTracker; itemTracker = nullptr;