aboutsummaryrefslogtreecommitdiff
path: root/engines/scumm/imuse/pcspk.cpp
diff options
context:
space:
mode:
authorMatthew Hoops2011-08-26 22:44:17 -0400
committerMatthew Hoops2011-08-26 22:44:17 -0400
commit4a69dc13d92e82fff85dc5a3a923b74ced259ffa (patch)
tree8945cd3745fd65f28b043caf7b1beddbbce2b2a1 /engines/scumm/imuse/pcspk.cpp
parentad293b249e74dd1cfbdbd721d02145efbdaf9eca (diff)
parent5e174cbfe466dbbe8e5470b0a00de1481b986181 (diff)
downloadscummvm-rg350-4a69dc13d92e82fff85dc5a3a923b74ced259ffa.tar.gz
scummvm-rg350-4a69dc13d92e82fff85dc5a3a923b74ced259ffa.tar.bz2
scummvm-rg350-4a69dc13d92e82fff85dc5a3a923b74ced259ffa.zip
Merge remote branch 'upstream/master' into pegasus
Diffstat (limited to 'engines/scumm/imuse/pcspk.cpp')
-rw-r--r--engines/scumm/imuse/pcspk.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/engines/scumm/imuse/pcspk.cpp b/engines/scumm/imuse/pcspk.cpp
index 01e2ab3b7d..cbf3446f10 100644
--- a/engines/scumm/imuse/pcspk.cpp
+++ b/engines/scumm/imuse/pcspk.cpp
@@ -380,7 +380,7 @@ int16 PcSpkDriver::getEffectModLevel(int16 level, int8 mod) {
}
}
-int16 PcSpkDriver::getRandMultipy(int16 input) {
+int16 PcSpkDriver::getRandScale(int16 input) {
if (_randBase & 1)
_randBase = (_randBase >> 1) ^ 0xB8;
else
@@ -470,7 +470,7 @@ void PcSpkDriver::initNextEnvelopeState(EffectEnvelope &env) {
uint16 stepCount = _effectEnvStepTable[getEffectModifier(((env.stateTargetLevels[lastState] & 0x7F) << 5) + env.modWheelSensitivity)];
if (env.stateTargetLevels[lastState] & 0x80)
- stepCount = getRandMultipy(stepCount);
+ stepCount = getRandScale(stepCount);
if (!stepCount)
stepCount = 1;
@@ -480,7 +480,7 @@ void PcSpkDriver::initNextEnvelopeState(EffectEnvelope &env) {
if (lastState != 2) {
totalChange = getEffectModLevel(env.maxLevel, (env.stateModWheelLevels[lastState] & 0x7F) - 31);
if (env.stateModWheelLevels[lastState] & 0x80)
- totalChange = getRandMultipy(totalChange);
+ totalChange = getRandScale(totalChange);
if (totalChange + env.startLevel > env.maxLevel)
totalChange = env.maxLevel - env.startLevel;
@@ -832,4 +832,3 @@ const uint16 PcSpkDriver::_frequencyTable[] = {
};
} // End of namespace Scumm
-