mirror of
https://github.com/TES3MP/TES3MP.git
synced 2025-09-26 14:36:40 -04:00
Don't play a weapon-down sound when unreadying a spell
This commit is contained in:
parent
92cc566fdc
commit
4ad28ed369
@ -399,12 +399,9 @@ bool CharacterController::updateNpcState()
|
||||
mUpperBodyState = UpperCharState_EquipingWeap;
|
||||
}
|
||||
|
||||
mWeaponType = weaptype;
|
||||
getWeaponGroup(mWeaponType, mCurrentWeapon);
|
||||
|
||||
if(weapon != inv.end())
|
||||
if(weapon != inv.end() && !(weaptype == WeapType_None && mWeaponType == WeapType_Spell))
|
||||
{
|
||||
std::string soundid = (mWeaponType == WeapType_None) ?
|
||||
std::string soundid = (weaptype == WeapType_None) ?
|
||||
MWWorld::Class::get(*weapon).getDownSoundId(*weapon) :
|
||||
MWWorld::Class::get(*weapon).getUpSoundId(*weapon);
|
||||
if(!soundid.empty())
|
||||
@ -413,6 +410,9 @@ bool CharacterController::updateNpcState()
|
||||
sndMgr->playSound3D(mPtr, soundid, 1.0f, 1.0f);
|
||||
}
|
||||
}
|
||||
|
||||
mWeaponType = weaptype;
|
||||
getWeaponGroup(mWeaponType, mCurrentWeapon);
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user