mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2025-01-10 19:09:45 +01: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:
parent
de26596d54
commit
951e1653a6
1 changed files with 8 additions and 2 deletions
|
@ -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()
|
||||
|
|
Loading…
Reference in a new issue