public GameModeExitFunc(){ foreach(Player, i) { if(gPlayerLoggedIn[i] == 1) { SavePlayer(i); gPlayerLoggedIn[i] = 0; } } GameModeExit();}