1
0
mirror of https://github.com/TerryCavanagh/VVVVVV.git synced 2024-06-17 10:08:29 +02:00

Move cleanup code to separate function

I will need to re-use this code, so it's best that it not be
copy-pasted.
This commit is contained in:
Misa 2021-02-15 17:52:41 -08:00 committed by Ethan Lee
parent de26596d54
commit 951e1653a6

View File

@ -76,6 +76,8 @@ static inline Uint32 get_framerate(const int slowdown)
static void inline deltaloop();
static void inline fixedloop();
static void cleanup();
int main(int argc, char *argv[])
{
char* baseDir = NULL;
@ -357,12 +359,16 @@ int main(int argc, char *argv[])
deltaloop();
}
cleanup();
return 0;
}
static void cleanup()
{
game.savestatsandsettings();
NETWORK_shutdown();
SDL_Quit();
FILESYSTEM_deinit();
return 0;
}
static void inline deltaloop()