////
// Process Routine
////
void CGameLauncher::ponder(const float deltaT)
{
    if(mpMsgDialog)
    {
        mpMsgDialog->processLogic();
        return;
    }

    if(mpDownloadDialog)
    {
        mpDownloadDialog->processLogic();
        return;
    }


    if(!mDonePatchSelection && m_chosenGame < 0)
    {
        ponderGameSelDialog(deltaT);
    }
    else if(m_chosenGame >= 0)
    {
        ponderPatchDialog();
    }
    else if(getQuit())
    {
        // User chose "exit". So make CG quit...
        gEventManager.add( new GMQuit() );
    }
}
Esempio n. 2
0
////
// Process Routine
////
void CGameLauncher::ponder(const float deltaT)
{
    if(mpMsgDialog)
    {
        mpMsgDialog->processLogic();
        return;
    }

    #ifdef DOWNLOADER
    if(mpGameStoreDialog)
    {
        // Command (Keyboard/Joystick) events for the game center dialog
        for( int cmd = IC_LEFT ; cmd < MAX_COMMANDS ; cmd++ )
        {
            if( gInput.getPressedCommand(cmd) )
            {
                mpGameStoreDialog->sendEvent(new CommandEvent( static_cast<InputCommands>(cmd) ));
                break;
            }
        }

        mpGameStoreDialog->processLogic();
        ponderDownloadDialog();
        return;
    }
    #endif

    // Button should disabled unless a game was selected
    if(mpStartButton)
    {
        if(mpSelList->getSelection() >= 0)
        {
            mpStartButton->enable(true);
        }
        else
        {
            mpStartButton->enable(false);
        }
    }


    if(!mDonePatchSelection && m_chosenGame < 0)
    {
        ponderGameSelDialog(deltaT);
    }
    else if(m_chosenGame >= 0)
    {
        ponderPatchDialog();
    }
    else if(getQuit())
    {
        // User chose "exit". So make CG quit...
        gEventManager.add( new GMQuit() );
    }
}