o Fixed bug where blink and leap would not get silenced by the silence upgrade

git-svn-id: https://unknownworlds.svn.cloudforge.com/ns1@470 67975925-1194-0748-b3d5-c16f83f1a3a1
This commit is contained in:
tankefugl 2006-05-09 21:17:17 +00:00
parent 35ddb6b401
commit d3a8529b3c

View file

@ -4368,7 +4368,9 @@ bool PM_BlinkMove (void)
SetUpgradeMask(&pmove->iuser4, MASK_ALIEN_MOVEMENT, true); SetUpgradeMask(&pmove->iuser4, MASK_ALIEN_MOVEMENT, true);
PM_NSPlaySound(CHAN_WEAPON, kBlinkSound, 1.0f, ATTN_NORM, 0, 94 + pmove->RandomLong(0, 0xf)); int theSilenceUpgradeLevel = AvHGetAlienUpgradeLevel(pmove->iuser4, MASK_UPGRADE_6);
float theVolumeScalar = 1.0f - theSilenceUpgradeLevel/3.0f;
PM_NSPlaySound(CHAN_WEAPON, kBlinkSound, theVolumeScalar, ATTN_NORM, 0, 94 + pmove->RandomLong(0, 0xf));
vec3_t forward, right, up; vec3_t forward, right, up;
AngleVectors(pmove->angles, forward, right, up); AngleVectors(pmove->angles, forward, right, up);
@ -4479,7 +4481,9 @@ bool PM_LeapMove()
SetUpgradeMask(&pmove->iuser4, MASK_ALIEN_MOVEMENT, true); SetUpgradeMask(&pmove->iuser4, MASK_ALIEN_MOVEMENT, true);
PM_NSPlaySound(CHAN_WEAPON, kLeapSound, 1.0f, ATTN_NORM, 0, 94 + pmove->RandomLong(0, 0xf)); int theSilenceUpgradeLevel = AvHGetAlienUpgradeLevel(pmove->iuser4, MASK_UPGRADE_6);
float theVolumeScalar = 1.0f - theSilenceUpgradeLevel/3.0f;
PM_NSPlaySound(CHAN_WEAPON, kLeapSound, theVolumeScalar, ATTN_NORM, 0, 94 + pmove->RandomLong(0, 0xf));
vec3_t forward, right, up; vec3_t forward, right, up;
AngleVectors(pmove->angles, forward, right, up); AngleVectors(pmove->angles, forward, right, up);