diff --git a/source/game.cpp b/source/game.cpp index d23f25a..d818a11 100644 --- a/source/game.cpp +++ b/source/game.cpp @@ -78,6 +78,7 @@ void Game::checkEventHandler() if (eventHandler->type == SDL_QUIT) { section.name = SECTION_PROG_QUIT; + screen->setBorderColor(stringToColor("black")); break; } else if ((eventHandler->type == SDL_KEYDOWN) and (eventHandler->key.repeat == 0)) diff --git a/source/intro.cpp b/source/intro.cpp index 97ce471..465d066 100644 --- a/source/intro.cpp +++ b/source/intro.cpp @@ -18,8 +18,6 @@ Intro::Intro(SDL_Renderer *renderer, Screen *screen, Asset *asset) loadingSound2 = JA_LoadMusic(asset->get("loading_sound2.ogg").c_str()); loadingSound3 = JA_LoadMusic(asset->get("loading_sound3.ogg").c_str()); - // text = new Text(asset->get("smb2.png"), asset->get("smb2.txt"), renderer); - // Inicializa variables preCounter = 0; counter = 0; @@ -31,6 +29,9 @@ Intro::Intro(SDL_Renderer *renderer, Screen *screen, Asset *asset) loadCounter = 0; load1 = true; load2 = false; + + // Cambia el color del borde + screen->setBorderColor(stringToColor("black")); } // Destructor diff --git a/source/logo.cpp b/source/logo.cpp index 00a348d..a683c73 100644 --- a/source/logo.cpp +++ b/source/logo.cpp @@ -63,6 +63,9 @@ Logo::Logo(SDL_Renderer *renderer, Screen *screen, Asset *asset) c = stringToColor("light_white"); color.push_back(c); + + // Cambia el color del borde + screen->setBorderColor(stringToColor("black")); } // Destructor diff --git a/source/title.cpp b/source/title.cpp index de477a6..4d37f5f 100644 --- a/source/title.cpp +++ b/source/title.cpp @@ -31,6 +31,9 @@ Title::Title(SDL_Renderer *renderer, Screen *screen, Asset *asset) letters.push_back(l); } letters[0].enabled = true; + + // Cambia el color del borde + screen->setBorderColor(stringToColor("magenta")); } // Destructor diff --git a/source/utils.cpp b/source/utils.cpp index 135a2da..6dcf506 100644 --- a/source/utils.cpp +++ b/source/utils.cpp @@ -229,7 +229,7 @@ color_t stringToColor(std::string str) } else - { + { // zxarne if (str == "black") { return {0x00, 0x00, 0x00};