diff options
author | Florian Kagerer | 2009-12-20 16:23:44 +0000 |
---|---|---|
committer | Florian Kagerer | 2009-12-20 16:23:44 +0000 |
commit | c1eaafcac766b894c8272a73df3c8ac6bc78e908 (patch) | |
tree | f4fd56d0fb3244f13c7f1f9c998a4699dc77f5eb | |
parent | ef0898c0b1b16372b3d3052c16ee2109cc144501 (diff) | |
download | scummvm-rg350-c1eaafcac766b894c8272a73df3c8ac6bc78e908.tar.gz scummvm-rg350-c1eaafcac766b894c8272a73df3c8ac6bc78e908.tar.bz2 scummvm-rg350-c1eaafcac766b894c8272a73df3c8ac6bc78e908.zip |
LOL: removed unused variable
svn-id: r46434
-rw-r--r-- | engines/kyra/lol.cpp | 2 | ||||
-rw-r--r-- | engines/kyra/lol.h | 1 | ||||
-rw-r--r-- | engines/kyra/timer_lol.cpp | 24 |
3 files changed, 11 insertions, 16 deletions
diff --git a/engines/kyra/lol.cpp b/engines/kyra/lol.cpp index f08246a6da..e56876ec07 100644 --- a/engines/kyra/lol.cpp +++ b/engines/kyra/lol.cpp @@ -238,7 +238,6 @@ LoLEngine::LoLEngine(OSystem *system, const GameFlags &flags) : KyraEngine_v1(sy _lightningSfxFrame = 0; _compassTimer = 0; - _timer3Para = 0; _scriptCharacterCycle = 0; _partyDamageFlags = -1; @@ -3511,7 +3510,6 @@ void LoLEngine::removeCharacterEffects(LoLCharacter *c, int first, int last) { } } - _timer3Para = 1; _timer->enable(3); } diff --git a/engines/kyra/lol.h b/engines/kyra/lol.h index 780b318775..8d4d937981 100644 --- a/engines/kyra/lol.h +++ b/engines/kyra/lol.h @@ -455,7 +455,6 @@ private: static const uint8 _clock2Timers[]; static const uint8 _numClock2Timers; - int _timer3Para; // sound int convertVolumeToMixer(int value); diff --git a/engines/kyra/timer_lol.cpp b/engines/kyra/timer_lol.cpp index c38d8cef10..fb3aa40672 100644 --- a/engines/kyra/timer_lol.cpp +++ b/engines/kyra/timer_lol.cpp @@ -107,7 +107,7 @@ void LoLEngine::timerProcessMonsters(int timerNum) { } void LoLEngine::timerSpecialCharacterUpdate(int timerNum) { - int v = 0; + int eventsLeft = 0; for (int i = 0; i < 4; i++) { if (!(_characters[i].flags & 1)) continue; @@ -117,8 +117,8 @@ void LoLEngine::timerSpecialCharacterUpdate(int timerNum) { continue; if (--_characters[i].characterUpdateDelay[ii] > 0) { - if (_characters[i].characterUpdateDelay[ii] > v) - v = _characters[i].characterUpdateDelay[ii]; + if (_characters[i].characterUpdateDelay[ii] > eventsLeft) + eventsLeft = _characters[i].characterUpdateDelay[ii]; continue; } @@ -127,8 +127,8 @@ void LoLEngine::timerSpecialCharacterUpdate(int timerNum) { if (_characters[i].weaponHit) { _characters[i].weaponHit = 0; _characters[i].characterUpdateDelay[ii] = calcMonsterSkillLevel(i, 6); - if (_characters[i].characterUpdateDelay[ii] > v) - v = _characters[i].characterUpdateDelay[ii]; + if (_characters[i].characterUpdateDelay[ii] > eventsLeft) + eventsLeft = _characters[i].characterUpdateDelay[ii]; } else { _characters[i].flags &= 0xfffb; } @@ -147,12 +147,12 @@ void LoLEngine::timerSpecialCharacterUpdate(int timerNum) { break; case 3: - v = rollDice(1, 2); - if (inflictDamage(i, v, 0x8000, 0, 0x80)) { + eventsLeft = rollDice(1, 2); + if (inflictDamage(i, eventsLeft, 0x8000, 0, 0x80)) { _txt->printMessage(2, getLangString(0x4022), _characters[i].name); _characters[i].characterUpdateDelay[ii] = 10; - if (_characters[i].characterUpdateDelay[ii] > v) - v = _characters[i].characterUpdateDelay[ii]; + if (_characters[i].characterUpdateDelay[ii] > eventsLeft) + eventsLeft = _characters[i].characterUpdateDelay[ii]; } break; @@ -184,12 +184,10 @@ void LoLEngine::timerSpecialCharacterUpdate(int timerNum) { } } - if (v) { + if (eventsLeft) _timer->enable(3); - _timer3Para = v * 15; - } else { + else _timer->disable(3); - } } void LoLEngine::timerProcessFlyingObjects(int timerNum) { |