- [NEW] Pantalla de game over

- [NEW] Stats
This commit is contained in:
2024-07-24 23:05:24 +02:00
parent 3a51938d80
commit 0a1b4f8715
8 changed files with 165 additions and 15 deletions

View File

@@ -254,14 +254,16 @@ namespace modules
if ( input::keyDown(SDL_SCANCODE_PAGEUP) /*&& selected->pos.z<max.z*/ ) { selected->pos.z++; actor::setDirty(selected); room::editor::modify(); }
}
bool loop()
int loop()
{
if (actor::hero::isDead()) return GAME_DEAD;
if (input::keyPressed(SDL_SCANCODE_ESCAPE))
{
if (console::isEnabled())
console::toggle();
else
return false;
return GAME_MENU;
}
if (input::keyPressed(SDL_SCANCODE_TAB) || input::keyPressed(SDL_SCANCODE_GRAVE) ) console::toggle();
@@ -369,7 +371,7 @@ namespace modules
{
console::draw();
draw::render();
return true;
return GAME_NONE;
}
@@ -752,7 +754,7 @@ namespace modules
};
draw::render();
return true;
return GAME_NONE;
}
}