mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2024-12-23 01:59:43 +01:00
Use quittomenu in gotoerrorloadinglevel
game.quittomenu() correctly resets state, as it's the function that's always used when quitting to menu. This fixes a bug where if a level with assets failed to load, it wouldn't unload the assets.
This commit is contained in:
parent
9387186083
commit
28ef3dd7bf
1 changed files with 1 additions and 3 deletions
|
@ -2522,10 +2522,8 @@ void scriptclass::translate_dialogue(void)
|
||||||
|
|
||||||
static void gotoerrorloadinglevel(void)
|
static void gotoerrorloadinglevel(void)
|
||||||
{
|
{
|
||||||
game.gamestate = TITLEMODE;
|
game.quittomenu();
|
||||||
game.createmenu(Menu::errorloadinglevel);
|
game.createmenu(Menu::errorloadinglevel);
|
||||||
map.nexttowercolour();
|
|
||||||
graphics.fademode = FADE_START_FADEIN; /* start fade in */
|
|
||||||
music.currentsong = -1; /* otherwise music.play won't work */
|
music.currentsong = -1; /* otherwise music.play won't work */
|
||||||
music.play(6); /* title screen music */
|
music.play(6); /* title screen music */
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue