mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2024-12-23 01:59:43 +01:00
Axe scriptclass::resetgametomenu
This creates the game over screen for dying in No Death Mode. It's three lines long and it's only called once. There's no reason it has to be a separate function. From the name it sounds like it was meant to be a generic function but it's anything but that. So just inline it in to where it's called.
This commit is contained in:
parent
593641ce82
commit
3758d61fe9
3 changed files with 3 additions and 10 deletions
|
@ -464,7 +464,9 @@ void gamelogic(void)
|
||||||
if (graphics.fademode == FADE_FULLY_BLACK)
|
if (graphics.fademode == FADE_FULLY_BLACK)
|
||||||
{
|
{
|
||||||
game.copyndmresults();
|
game.copyndmresults();
|
||||||
script.resetgametomenu();
|
obj.entities.clear();
|
||||||
|
game.quittomenu();
|
||||||
|
game.createmenu(Menu::gameover);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
|
@ -2365,13 +2365,6 @@ void scriptclass::run(void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void scriptclass::resetgametomenu(void)
|
|
||||||
{
|
|
||||||
obj.entities.clear();
|
|
||||||
game.quittomenu();
|
|
||||||
game.createmenu(Menu::gameover);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void gotoerrorloadinglevel(void)
|
static void gotoerrorloadinglevel(void)
|
||||||
{
|
{
|
||||||
game.createmenu(Menu::errorloadinglevel);
|
game.createmenu(Menu::errorloadinglevel);
|
||||||
|
|
|
@ -77,8 +77,6 @@ public:
|
||||||
|
|
||||||
void run(void);
|
void run(void);
|
||||||
|
|
||||||
void resetgametomenu(void);
|
|
||||||
|
|
||||||
void startgamemode(enum StartMode mode);
|
void startgamemode(enum StartMode mode);
|
||||||
|
|
||||||
void teleport(void);
|
void teleport(void);
|
||||||
|
|
Loading…
Reference in a new issue