本文整理汇总了C++中COptions::GetSFXVolume方法的典型用法代码示例。如果您正苦于以下问题:C++ COptions::GetSFXVolume方法的具体用法?C++ COptions::GetSFXVolume怎么用?C++ COptions::GetSFXVolume使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类COptions
的用法示例。
在下文中一共展示了COptions::GetSFXVolume方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1:
CEnemyPsycrow::CEnemyPsycrow()
{
CSGD_EventSystem *pES = CSGD_EventSystem::GetInstance();
CSGD_TextureManager *pTM = CSGD_TextureManager::GetInstance();
COptions *op = COptions::GetInstance();
pES->RegisterClient("psycrow fire", this);
pES->RegisterClient("state transition 1", this);
pES->RegisterClient("state transition 2", this);
pES->RegisterClient("state transition 3", this);
pES->RegisterClient("state transition 4", this);
m_nState = PSYCROW_STATE1;
m_nSoundID = CSGD_WaveManager::GetInstance()->LoadWave("Resource/sounds/JoA_Squawk.wav");
CSGD_WaveManager::GetInstance()->SetVolume(m_nSoundID, op->GetSFXVolume() - 40);
m_fFireReady = 5.0f;
m_fHitTimer = 0.4f;
m_nOffset = 0;
bIsFired = false;
m_fFiringTimer = 0.5f;
m_fSineFloat = 3.14f;
m_nColor = 255;
m_nScale = 1.5f;
SetHP(250 * op->GetDifficulty());
SetVelX(75 * op->GetDifficulty());
SetVelY(0.0f);
SetXFlip(-1);
SetHeight(84);
SetWidth(70);
SetPosX(320);
SetPosY(240);
SetPower(0);
SetType(ACTOR_ENEMY);
SetScoreValue(1000 * op->GetDifficulty());
SetHit(false);
pBullet = NULL;
bIsFiring = false;
}
示例2:
CEnemyBusiness::CEnemyBusiness()
{
CSGD_EventSystem *pES = CSGD_EventSystem::GetInstance();
CSGD_TextureManager *pTM = CSGD_TextureManager::GetInstance();
COptions *op = COptions::GetInstance();
CSGD_WaveManager *pWM = CSGD_WaveManager::GetInstance();
pES->RegisterClient("businessman fire", this);
SetHP(50 *op->GetDifficulty());
SetVelX(-50.0f * op->GetDifficulty());
SetVelY(0.0f);
SetXFlip(-1);
SetHeight(63);
SetWidth(86);
SetPosX(1000);
SetPosY(220);
SetPower(0);
SetType(ACTOR_ENEMY);
SetScoreValue(200 * op->GetDifficulty());
SetHit(false);
pBullet = NULL;
bIsFiring = false;
m_fFireReady = 5.0f;
m_fHitTimer = 1.0f;
m_nOffset = 0;
m_fFiringTimer = 1.0f;
rEnemyRect.top = 18;
rEnemyRect.bottom = 61;
rEnemyRect.left = 2;
rEnemyRect.right = 54;
m_nSoundID = pWM->LoadWave("Resource/sounds/JoA_Scream.wav");
pWM->SetVolume(m_nSoundID,op->GetSFXVolume() - 25);
}