当前位置: 首页>>代码示例>>C++>>正文


C++ CAudioManager::Process方法代码示例

本文整理汇总了C++中CAudioManager::Process方法的典型用法代码示例。如果您正苦于以下问题:C++ CAudioManager::Process方法的具体用法?C++ CAudioManager::Process怎么用?C++ CAudioManager::Process使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在CAudioManager的用法示例。


在下文中一共展示了CAudioManager::Process方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: Process

void CNetworkManager::Process()
{
    // Get our file transfer manager
    CFileTransferManager * pFileTransferManager = g_pClient->GetFileTransfer();

    // If our file transfer class exists process it
    if(pFileTransferManager)
        pFileTransferManager->Process();

    // Have we joined a server and not joined a game yet?
    if(m_bJoinedServer && !m_bJoinedGame)
    {
        // Get our local player
        CLocalPlayer * pLocalPlayer = g_pClient->GetLocalPlayer();

        // Is the file transfer list empty?
        if(pFileTransferManager->IsComplete() && pLocalPlayer->IsConnectFinished())
        {
            // Flag ourselves as joined a game
            m_bJoinedGame = true;

            // Respawn the local player
            pLocalPlayer->Respawn();
        }
    }

    if(!m_pNetClient)
        return;

    // Process the net client
    m_pNetClient->Process();

    // Are we connected to a server?
    if(m_pNetClient->IsConnected())
    {
        // If our streamer exists, process it
        CStreamer * pStreamer = g_pClient->GetStreamer();

        if(pStreamer)
            pStreamer->Pulse();

        // Is our script timer manager exists, process it
        CScriptTimerManager * pScriptTimerManager = g_pClient->GetClientScriptManager()->GetScriptTimerManager();
        if(pScriptTimerManager)
            pScriptTimerManager->Pulse();

        // If our player manager exists process it
        CPlayerManager * pPlayerManager = g_pClient->GetPlayerManager();

        if(pPlayerManager)
            pPlayerManager->Pulse();

        // If our vehicle manager exists process it
        CVehicleManager * pVehicleManager = g_pClient->GetVehicleManager();

        if(pVehicleManager)
            pVehicleManager->Pulse();

        // If our checkpoint manager exists process it
        CCheckpointManager * pCheckpointManager = g_pClient->GetCheckpointManager();

        if(pCheckpointManager)
            pCheckpointManager->Pulse();

        // If our object manager exists process it
        CObjectManager * pObjectManager = g_pClient->GetObjectManager();

        if(pObjectManager)
            pObjectManager->Process();

        // Process the audio manager
        CAudioManager * pAudioManager = g_pClient->GetAudioManager();

        if(pAudioManager)
            pAudioManager->Process();

        // Process the actor manager
        CActorManager * pActorManager = g_pClient->GetActorManager();

        if(pActorManager)
            pActorManager->Process();
    }
}
开发者ID:JamesConway69,项目名称:ivmultiplayer,代码行数:83,代码来源:CNetworkManager.cpp


注:本文中的CAudioManager::Process方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。