aboutsummaryrefslogtreecommitdiff
path: root/engines/kyra
diff options
context:
space:
mode:
authorJohannes Schickel2009-06-02 00:10:13 +0000
committerJohannes Schickel2009-06-02 00:10:13 +0000
commita4292afcdc7be36506871bf5752d9ae0ef564b2f (patch)
tree9e75ef41084bd54068a1b902795932e2720ded26 /engines/kyra
parentfae4192b37847e8a1f7e43b74fb679119f46c548 (diff)
downloadscummvm-rg350-a4292afcdc7be36506871bf5752d9ae0ef564b2f.tar.gz
scummvm-rg350-a4292afcdc7be36506871bf5752d9ae0ef564b2f.tar.bz2
scummvm-rg350-a4292afcdc7be36506871bf5752d9ae0ef564b2f.zip
Formatting and whitespaces again.
svn-id: r41120
Diffstat (limited to 'engines/kyra')
-rw-r--r--engines/kyra/lol.cpp16
-rw-r--r--engines/kyra/lol.h2
-rw-r--r--engines/kyra/scene_lol.cpp2
-rw-r--r--engines/kyra/script_lol.cpp8
-rw-r--r--engines/kyra/script_tim.cpp2
-rw-r--r--engines/kyra/sequences_lol.cpp10
-rw-r--r--engines/kyra/sprites_lol.cpp10
7 files changed, 25 insertions, 25 deletions
diff --git a/engines/kyra/lol.cpp b/engines/kyra/lol.cpp
index 3dfd2b2ceb..0a428e78c9 100644
--- a/engines/kyra/lol.cpp
+++ b/engines/kyra/lol.cpp
@@ -321,7 +321,7 @@ LoLEngine::~LoLEngine() {
releaseMonsterShapes(i);
delete[] _monsterShapes;
- delete[] _monsterPalettes;
+ delete[] _monsterPalettes;
delete[] _monsterShapesEx;
if (_automapShapes)
@@ -2439,11 +2439,11 @@ void LoLEngine::processMagicHandOfFate(int spellLevel) {
if (spellLevel < 2) {
uint16 b1 = calcNewBlockPosition(_currentBlock, _currentDirection);
uint16 b2 = calcNewBlockPosition(b1, _currentDirection);
-
+
if (!testWallFlag(b2, 0, 4)) {
if (!(_levelBlockProperties[b2].assignedObjects & 0x8000)) {
checkSceneUpdateNeed(b1);
-
+
uint16 dir = (_currentDirection << 1);
uint16 o = _levelBlockProperties[b1].assignedObjects;
while (o & 0x8000) {
@@ -3368,7 +3368,7 @@ void LoLEngine::restoreSwampPalette() {
void LoLEngine::launchMagicViper() {
_partyAwake = true;
- int d = 0;
+ int d = 0;
for (uint16 b = _currentBlock; d < 3; d++) {
uint16 o = _levelBlockProperties[b].assignedObjects;
if (o & 0x8000)
@@ -3385,15 +3385,15 @@ void LoLEngine::launchMagicViper() {
int numFrames = mov->open("viper.wsa", 1, 0);
if (!mov->opened())
error("Viper: Unable to load viper.wsa");
-
+
static const uint8 viperAnimData[] = { 15, 25, 20, 10, 25, 20, 5, 25, 20, 0, 25, 20 };
const uint8 *v = &viperAnimData[d * 3];
int frm = v[0];
-
+
for (bool running = true; running;) {
uint32 etime = _system->getMillis() + 5 * _tickLength;
_screen->copyPage(12, 2);
-
+
if (frm == v[2])
snd_playSoundEffect(172, -1);
@@ -3405,7 +3405,7 @@ void LoLEngine::launchMagicViper() {
if (frm > v[1])
running = false;
}
-
+
mov->close();
delete mov;
diff --git a/engines/kyra/lol.h b/engines/kyra/lol.h
index 99faea01f6..200aae148a 100644
--- a/engines/kyra/lol.h
+++ b/engines/kyra/lol.h
@@ -854,7 +854,7 @@ private:
void generateBrightnessPalette(uint8 *src, uint8 *dst, int brightness, int modifier);
void generateFlashPalette(uint8 *src, uint8 *dst, int colorFlags);
void updateSequenceBackgroundAnimations();
-
+
bool _dialogueField;
uint8 **_itemIconShapes;
int _numItemIconShapes;
diff --git a/engines/kyra/scene_lol.cpp b/engines/kyra/scene_lol.cpp
index 1b7e305218..9431220a56 100644
--- a/engines/kyra/scene_lol.cpp
+++ b/engines/kyra/scene_lol.cpp
@@ -1338,7 +1338,7 @@ void LoLEngine::processGasExplosion(int soundId) {
while (_screen->fadePaletteStep(p2, _screen->_currentPalette, _system->getMillis() - ctime, 50))
updateInput();
}
-
+
_screen->copyPage(12, 2);
_screen->setCurPage(cp);
diff --git a/engines/kyra/script_lol.cpp b/engines/kyra/script_lol.cpp
index 2f2879959f..7ffdabc850 100644
--- a/engines/kyra/script_lol.cpp
+++ b/engines/kyra/script_lol.cpp
@@ -1806,7 +1806,7 @@ int LoLEngine::olol_findAssignedMonster(EMCState *script) {
uint16 o = stackPos(1) == -1 ? _levelBlockProperties[stackPos(0)].assignedObjects : findObject(stackPos(1))->nextAssignedObject;
while (o) {
if (o & 0x8000)
- return o & 0x7fff;
+ return o & 0x7fff;
o = findObject(o)->nextAssignedObject;
}
return -1;
@@ -1923,7 +1923,7 @@ int LoLEngine::olol_findInventoryItem(EMCState *script) {
if (stackPos(1) == -1) {
cur = 0;
last = 4;
- }
+ }
for (;cur < last; cur++) {
if (!(_characters[cur].flags & 1))
continue;
@@ -1932,7 +1932,7 @@ int LoLEngine::olol_findInventoryItem(EMCState *script) {
continue;
if (_itemsInPlay[_characters[cur].items[i]].itemPropertyIndex == stackPos(2))
return cur;
- }
+ }
}
return -1;
}
@@ -1956,7 +1956,7 @@ int LoLEngine::olol_changeItemTypeOrFlag(EMCState *script) {
if (stackPos(1) == 4) {
i->itemPropertyIndex = r;
return r;
- } else if (stackPos(1) == 15) {
+ } else if (stackPos(1) == 15) {
i->shpCurFrame_flg = (i->shpCurFrame_flg & 0xe000) | r;
return r;
}
diff --git a/engines/kyra/script_tim.cpp b/engines/kyra/script_tim.cpp
index 1b1fd61d3b..e9ca23a4c9 100644
--- a/engines/kyra/script_tim.cpp
+++ b/engines/kyra/script_tim.cpp
@@ -381,7 +381,7 @@ void TIMInterpreter::displayText(uint16 textId, int16 flags, uint8 color) {
if (!flags)
_screen->copyRegionToBuffer(0, 0, 0, 320, 40, _textAreaBuffer);
-
+
char backupChar = 0;
char *str = text;
int y = 0;
diff --git a/engines/kyra/sequences_lol.cpp b/engines/kyra/sequences_lol.cpp
index 9463989b86..bba384ced4 100644
--- a/engines/kyra/sequences_lol.cpp
+++ b/engines/kyra/sequences_lol.cpp
@@ -686,7 +686,7 @@ void LoLEngine::showStarcraftLogo() {
void LoLEngine::setupEpilogueData(bool load) {
static const char * const fileListCD[] = {
- "GENERAL.PAK", "INTROVOC.PAK", "STARTUP.PAK",
+ "GENERAL.PAK", "INTROVOC.PAK", "STARTUP.PAK",
"FINALE.PAK", "FINALE1.PAK", "FINALE2.PAK", 0
};
@@ -1065,7 +1065,7 @@ void LoLEngine::processCredits(char *t, int dimState, int page, int delayTime) {
monsterX = _outroRightMonsterPos[monsterAnimFrame * 2 + 0];
monsterY = _outroRightMonsterPos[monsterAnimFrame * 2 + 1];
-
+
_screen->drawShape(page, doorShape, 0, 0, 20, 0x10);
} else {
doorSD = 20;
@@ -1104,10 +1104,10 @@ void LoLEngine::processCredits(char *t, int dimState, int page, int delayTime) {
_screen->printText(s.str, (_screen->_curDim->sx << 3) + x, _screen->_curDim->sy + y, 0xDC, 0x00);
_screen->_curPage = 0;
}
-
+
--s.y;
}
-
+
_screen->copyToPage0(_screen->_curDim->sy, _screen->_curDim->h, page, animBlock);
if (strings[1].y < -10) {
@@ -1145,7 +1145,7 @@ void LoLEngine::processCredits(char *t, int dimState, int page, int delayTime) {
void LoLEngine::loadOutroShapes(int file, uint8 **storage) {
_screen->loadBitmap(_outroShapeFileTable[file], 5, 5, 0);
-
+
for (int i = 0; i < 12; ++i) {
delete[] storage[i];
if (i < 8)
diff --git a/engines/kyra/sprites_lol.cpp b/engines/kyra/sprites_lol.cpp
index 81dbb5f33c..8d856796ff 100644
--- a/engines/kyra/sprites_lol.cpp
+++ b/engines/kyra/sprites_lol.cpp
@@ -130,7 +130,7 @@ void LoLEngine::releaseMonsterShapes(int monsterIndex) {
for (int ii = pos; ii < pos2; ii++) {
if (_monsterShapes[ii] == t)
_monsterShapes[ii] = 0;
- }
+ }
}
if (_monsterPalettes[pos]) {
@@ -143,7 +143,7 @@ void LoLEngine::releaseMonsterShapes(int monsterIndex) {
int pos = (monsterIndex * 192) + i;
if (_monsterShapesEx[pos]) {
delete[] _monsterShapesEx[pos];
- _monsterShapesEx[pos] = 0;
+ _monsterShapesEx[pos] = 0;
}
}
}
@@ -280,7 +280,7 @@ void LoLEngine::placeMonster(MonsterInPlay *monster, uint16 x, uint16 y) {
// WORKAROUND: Some monsters in the white tower have sound id's of 0xff. This is definitely a bug, since the
// last valid track number is 249 and there is no specific handling for 0xff. Nonetheless this wouldn't
- // cause problems in the original code, because it just so happens that the invalid memory address points
+ // cause problems in the original code, because it just so happens that the invalid memory address points
// to an entry in _ingameGMSoundIndex which just so happens to have a value of -1
if (monster->properties->sounds[0] == 0 || monster->properties->sounds[0] == 255 || cont == false)
return;
@@ -538,9 +538,9 @@ int LoLEngine::calcMonsterSkillLevel(int id, int a) {
r = (r * _monsterModifiers[3 + _monsterDifficulty]) >> 8;
} else {
if (_characters[id].skillLevels[1] > 7)
- r = (r- (r >> 1));
+ r = (r - (r >> 1));
else if (_characters[id].skillLevels[1] > 3 && _characters[id].skillLevels[1] <= 7)
- r = (r- (r >> 2));
+ r = (r - (r >> 2));
}
return r;