コード例 #1
0
void GameStateManager::goToWinScreen()
{
	currentGameState = GS_WIN_SCREEN;
	if (isWorldRenderable())
		unloadCurrentLevel();
	//graphics->clearWorldTextures();
}
コード例 #2
0
void GameStateManager::goToGameOver()
{
	currentGameState = GS_GAME_OVER;
	if (isWorldRenderable())
		unloadCurrentLevel();
	//graphics->clearWorldTextures();

}
コード例 #3
0
/*
shutdown - this method is called when the user wants to quit the
application. This method updates the game state such that all
world resources are released and the game loop does not iterate
again.
*/
void GameStateManager::shutdown()
{
	// MAKE SURE THE GAME LOOP DOESN'T GO AROUND AGAIN
	currentGameState = GS_EXIT_GAME;

	// CLEAR LEFT OVER DATA
	if (isWorldRenderable())
		unloadCurrentLevel();
}