예제 #1
0
파일: game.cpp 프로젝트: EXL/NXEngine
void Game::tick(void)
{
	debug_clear();
	
	if (game.paused)
	{
		tickfunctions[game.paused].OnTick();
	}
	else
	{
		// record/playback replays
		Replay::run();
		
		// run scripts
		RunScripts();
		
		// call the tick function for the current game mode
		tickfunctions[game.mode].OnTick();
	}
	
	DrawDebug();
	console.Draw();
}
예제 #2
0
파일: game.cpp 프로젝트: Fordi/nxengine-evo
void Game::tick(void)
{
	debug_clear();
	
	if (game.paused)
	{
		tickfunctions[game.paused].OnTick();
	}
	else
	{
		// run scripts
		RunScripts();
		
		// call the tick function for the current game mode
		tickfunctions[game.mode].OnTick();
		if (justpushed(ESCKEY) && (game.mode == GM_NORMAL || game.mode == GM_INVENTORY || game.mode == GM_MAP_SYSTEM || game.mode == GM_CREDITS))
		{
		    game.pause(GP_PAUSED);
		}
	}
	
	DrawDebug();
	console.Draw();
}