aboutsummaryrefslogtreecommitdiff
path: root/engines/kyra/sound_lol.cpp
diff options
context:
space:
mode:
authorJohannes Schickel2013-01-09 06:00:35 +0100
committerJohannes Schickel2013-01-09 06:01:28 +0100
commit8d5b4b75d406bb56130fb4ccd91edda4ba1f4906 (patch)
treef6f481c09553c1f454c31bbb88490de26e326069 /engines/kyra/sound_lol.cpp
parentff296175bc558ce5758a0948ab91333a6d3b918e (diff)
downloadscummvm-rg350-8d5b4b75d406bb56130fb4ccd91edda4ba1f4906.tar.gz
scummvm-rg350-8d5b4b75d406bb56130fb4ccd91edda4ba1f4906.tar.bz2
scummvm-rg350-8d5b4b75d406bb56130fb4ccd91edda4ba1f4906.zip
KYRA: Make all hex constants use uppercase letters.
Done with: git ls-files "*.cpp" *".h" | xargs sed -i -e 's/0x\([0-9a-f]*\)/0x\U\1/g'
Diffstat (limited to 'engines/kyra/sound_lol.cpp')
-rw-r--r--engines/kyra/sound_lol.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/engines/kyra/sound_lol.cpp b/engines/kyra/sound_lol.cpp
index 3c2c931445..02ea3f44a8 100644
--- a/engines/kyra/sound_lol.cpp
+++ b/engines/kyra/sound_lol.cpp
@@ -60,7 +60,7 @@ bool LoLEngine::snd_playCharacterSpeech(int id, int8 speaker, int) {
Common::String pattern2 = Common::String::format("%02d", id & 0x4000 ? 0 : _curTlkFile);
if (id & 0x4000) {
- pattern1 = Common::String::format("%03X", id & 0x3fff);
+ pattern1 = Common::String::format("%03X", id & 0x3FFF);
} else if (id < 1000) {
pattern1 = Common::String::format("%03d", id);
} else {
@@ -164,7 +164,7 @@ void LoLEngine::snd_playSoundEffect(int track, int volume) {
if (track == -1 || track >= _ingameSoundListSize)
return;
- volume &= 0xff;
+ volume &= 0xFF;
int16 prIndex = (int16)READ_LE_UINT16(&_ingameSoundIndex[track * 2 + 1]);
uint16 priority = (prIndex > 0) ? (prIndex * volume) >> 8 : -prIndex;
@@ -214,8 +214,8 @@ bool LoLEngine::snd_processEnvironmentalSoundEffect(int soundId, int block) {
uint16 cbl = _currentBlock;
for (int i = 3; i > 0; i--) {
- int dir = calcMonsterDirection(cbl & 0x1f, cbl >> 5, block & 0x1f, block >> 5);
- cbl = (cbl + blockShiftTable[dir]) & 0x3ff;
+ int dir = calcMonsterDirection(cbl & 0x1F, cbl >> 5, block & 0x1F, block >> 5);
+ cbl = (cbl + blockShiftTable[dir]) & 0x3FF;
if (cbl != block) {
if (testWallFlag(cbl, 0, 1))
_environmentSfxVol >>= 1;