aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorian Kagerer2010-01-18 00:56:30 +0000
committerFlorian Kagerer2010-01-18 00:56:30 +0000
commit371a2a9ee9009d7acd6e837fa2ee6c0e383e058c (patch)
treea936a710df9170bd4dcbd089d5ef876ba8a38433
parent9593b72483a6646fbdbac4a1df961374a922bae8 (diff)
downloadscummvm-rg350-371a2a9ee9009d7acd6e837fa2ee6c0e383e058c.tar.gz
scummvm-rg350-371a2a9ee9009d7acd6e837fa2ee6c0e383e058c.tar.bz2
scummvm-rg350-371a2a9ee9009d7acd6e837fa2ee6c0e383e058c.zip
LOL: fixed spell array size
svn-id: r47353
-rw-r--r--engines/kyra/lol.cpp2
-rw-r--r--engines/kyra/lol.h2
-rw-r--r--engines/kyra/saveload_lol.cpp1
3 files changed, 3 insertions, 2 deletions
diff --git a/engines/kyra/lol.cpp b/engines/kyra/lol.cpp
index 3290e80231..314a360813 100644
--- a/engines/kyra/lol.cpp
+++ b/engines/kyra/lol.cpp
@@ -891,7 +891,7 @@ void LoLEngine::startupNew() {
_inventory[1] = makeItem(217, 0, 0);
_inventory[2] = makeItem(218, 0, 0);
- memset(_availableSpells, -1, 7);
+ memset(_availableSpells, -1, 8);
_availableSpells[0] = 0;
setupScreenDims();
diff --git a/engines/kyra/lol.h b/engines/kyra/lol.h
index 7a49085f6c..d4e7187fe6 100644
--- a/engines/kyra/lol.h
+++ b/engines/kyra/lol.h
@@ -1390,7 +1390,7 @@ private:
void inflictMagicalDamageForBlock(int block, int attacker, int damage, int index);
ActiveSpell _activeSpell;
- int8 _availableSpells[7];
+ int8 _availableSpells[8];
int _selectedSpell;
const SpellProperty *_spellProperties;
int _spellPropertiesSize;
diff --git a/engines/kyra/saveload_lol.cpp b/engines/kyra/saveload_lol.cpp
index 480714e5c9..ccce8b58f7 100644
--- a/engines/kyra/saveload_lol.cpp
+++ b/engines/kyra/saveload_lol.cpp
@@ -267,6 +267,7 @@ Common::Error LoLEngine::loadGameState(int slot) {
gui_drawPlayField();
timerSpecialCharacterUpdate(0);
_flagsTable[73] |= 0x08;
+ _availableSpells[7] = -1;
while (!_screen->isMouseVisible())
_screen->showMouse();