Recorded some voice samples for Tux for testing, continuing to include sfx calls for special in game events.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/branches/irrlicht@3901 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
parent
6318008c87
commit
5f071a7759
@ -64,9 +64,6 @@ void Attachment::set(attachmentType type, float time, Kart *current_kart)
|
||||
if(m_initial_speed <= 1.5) m_initial_speed = 1.5; // if going very slowly or backwards, braking won't remove parachute
|
||||
}
|
||||
|
||||
// Play appropriate custom character sound
|
||||
// m_kart->playCustomSFX(SFXManager::CUSTOM_ATTACH);
|
||||
|
||||
} // set
|
||||
|
||||
// -----------------------------------------------------------------------------
|
||||
@ -162,6 +159,8 @@ void Attachment::moveBombFromTo(Kart *from, Kart *to)
|
||||
to->setAttachmentType(ATTACH_BOMB,
|
||||
from->getAttachment()->getTimeLeft()+
|
||||
stk_config->m_bomb_time_increase, from);
|
||||
|
||||
to->playCustomSFX(SFXManager::CUSTOM_ATTACH);
|
||||
from->getAttachment()->clear();
|
||||
} // moveBombFromTo
|
||||
|
||||
|
@ -119,7 +119,7 @@ Material *Powerup::getIcon()
|
||||
void Powerup::use()
|
||||
{
|
||||
// Play custom kart sound when collectible is used
|
||||
m_owner->playCustomSFX(SFXManager::CUSTOM_SHOOT);
|
||||
if (m_type != POWERUP_NOTHING) m_owner->playCustomSFX(SFXManager::CUSTOM_SHOOT);
|
||||
|
||||
// FIXME - for some collectibles, set() is never called
|
||||
if(m_sound_use == NULL) m_sound_use = sfx_manager->newSFX(SFXManager::SOUND_SHOT);
|
||||
|
@ -413,7 +413,12 @@ void Kart::collectedItem(const Item &item, int add_info)
|
||||
|
||||
switch (type)
|
||||
{
|
||||
case Item::ITEM_BANANA : m_attachment.hitBanana(item, add_info); break;
|
||||
case Item::ITEM_BANANA:
|
||||
m_attachment.hitBanana(item, add_info);
|
||||
// Play appropriate custom character sound
|
||||
playCustomSFX(SFXManager::CUSTOM_ATTACH);
|
||||
break;
|
||||
|
||||
case Item::ITEM_SILVER_COIN: m_collected_energy++ ; break;
|
||||
case Item::ITEM_GOLD_COIN : m_collected_energy += 3 ; break;
|
||||
case Item::ITEM_BONUS_BOX :
|
||||
@ -429,6 +434,8 @@ void Kart::collectedItem(const Item &item, int add_info)
|
||||
m_body->setLinearVelocity(m_body->getLinearVelocity()*0.3f);
|
||||
m_goo_sound->position(getXYZ());
|
||||
m_goo_sound->play();
|
||||
// Play appropriate custom character sound
|
||||
playCustomSFX(SFXManager::CUSTOM_GOO);
|
||||
break;
|
||||
default : break;
|
||||
} // switch TYPE
|
||||
@ -494,6 +501,8 @@ void Kart::handleExplosion(const Vec3& pos, bool direct_hit)
|
||||
int sign_bits = rand(); // To select plus or minus randomnly, assuming 15 bit at least
|
||||
if(direct_hit)
|
||||
{
|
||||
// Play associated kart sound
|
||||
playCustomSFX(SFXManager::CUSTOM_EXPLODE);
|
||||
float sign_a = (sign_bits & (0x1 << 8)) ? 1.0f : -1.0f;
|
||||
float sign_b = (sign_bits & (0x1 << 9)) ? 1.0f : -1.0f;
|
||||
float sign_c = (sign_bits & (0x1 << 10)) ? 1.0f : -1.0f;
|
||||
|
@ -369,7 +369,7 @@ void PlayerKart::collectedItem(const Item &item, int add_info)
|
||||
switch(item.getType())
|
||||
{
|
||||
case Item::ITEM_BANANA:
|
||||
m_ugh_sound->play();
|
||||
//m_ugh_sound->play();
|
||||
break;
|
||||
case Item::ITEM_BUBBLEGUM:
|
||||
//The skid sound is played by the kart class. Do nothing here.
|
||||
|
Loading…
Reference in New Issue
Block a user