Exemplo n.º 1
0
//
// D_DoomLoop
//
void D_DoomLoop (void)
{
    while (1)
    {
        try
        {
            D_RunTics(SV_RunTics, SV_DisplayTics);
        }
        catch (CRecoverableError &error)
        {
            Printf (PRINT_HIGH, "ERROR: %s\n", error.GetMsg().c_str());
            Printf (PRINT_HIGH, "sleeping for 10 seconds before map reload...");

            // denis - drop clients
            SV_SendDisconnectSignal();

            // denis - sleep 10 seconds to conserve server resources (in case of recurring problem)
            I_Sleep(10 * 1000LL * 1000LL * 1000LL);

            // denis - reload with current settings
            G_ChangeMap ();

            // denis - todo - throw I_FatalError if this keeps happening
        }
    }
}
Exemplo n.º 2
0
//
//  D_DoomLoop
//
void D_DoomLoop (void)
{
	while (1)
	{
		try
		{
			D_RunTics(CL_RunTics, CL_RenderTics);
		}
		catch (CRecoverableError &error)
		{
			Printf_Bold ("\n%s\n", error.GetMsg().c_str());

			CL_QuitNetGame ();

			G_ClearSnapshots ();

			DThinker::DestroyAllThinkers();

			players.clear();

			gameaction = ga_fullconsole;
		}
	}
}