diff options
author | Filippos Karapetis | 2007-05-01 21:48:18 +0000 |
---|---|---|
committer | Filippos Karapetis | 2007-05-01 21:48:18 +0000 |
commit | 6ca558f0ff2126a0fbac2cdb789fb8cf2b5e48bd (patch) | |
tree | 8bb8ccbaec59576cfb5e05569d9020b51f6e0a07 /engines/saga | |
parent | d08eeff7002d7296b2367242b66ca2e03c1ce4a1 (diff) | |
download | scummvm-rg350-6ca558f0ff2126a0fbac2cdb789fb8cf2b5e48bd.tar.gz scummvm-rg350-6ca558f0ff2126a0fbac2cdb789fb8cf2b5e48bd.tar.bz2 scummvm-rg350-6ca558f0ff2126a0fbac2cdb789fb8cf2b5e48bd.zip |
Fix for verbs in IHNM
svn-id: r26732
Diffstat (limited to 'engines/saga')
-rw-r--r-- | engines/saga/displayinfo.h | 18 | ||||
-rw-r--r-- | engines/saga/interface.cpp | 19 |
2 files changed, 20 insertions, 17 deletions
diff --git a/engines/saga/displayinfo.h b/engines/saga/displayinfo.h index 25b7e5327d..4820533623 100644 --- a/engines/saga/displayinfo.h +++ b/engines/saga/displayinfo.h @@ -283,14 +283,16 @@ static const GameDisplayInfo ITE_DisplayInfo = { #define IHNM_CONVERSE_TEXT_LINES 10 static PanelButton IHNM_MainPanelButtons[] = { - {kPanelButtonVerb, 106,12, 114,30, kVerbIHNMWalk,'w',0, 0,1,0}, - {kPanelButtonVerb, 106,44, 114,30, kVerbIHNMLookAt,'l',0, 2,3,0}, - {kPanelButtonVerb, 106,76, 114,30, kVerbIHNMTake,'k',0, 4,5,0}, - {kPanelButtonVerb, 106,108, 114,30, kVerbIHNMUse,'u',0, 6,7,0}, - {kPanelButtonVerb, 223,12, 114,30, kVerbIHNMTalkTo,'t',0, 8,9,0}, - {kPanelButtonVerb, 223,44, 114,30, kVerbIHNMSwallow,'s',0, 10,11,0}, - {kPanelButtonVerb, 223,76, 114,30, kVerbIHNMGive,'g',0, 12,13,0}, - {kPanelButtonVerb, 223,108, 114,30, kVerbIHNMPush,'p',0, 14,15,0}, + // TODO: The +2's are needed here to fix the verbs, investigate why + // The computation of textid in Interface::drawVerbPanelText has also been changed accordingly + {kPanelButtonVerb, 106,12, 114,30, kVerbIHNMWalk + 2,'w',0, 0,1,0}, + {kPanelButtonVerb, 106,44, 114,30, kVerbIHNMLookAt + 2,'l',0, 2,3,0}, + {kPanelButtonVerb, 106,76, 114,30, kVerbIHNMTake + 2,'k',0, 4,5,0}, + {kPanelButtonVerb, 106,108, 114,30, kVerbIHNMUse + 2,'u',0, 6,7,0}, + {kPanelButtonVerb, 223,12, 114,30, kVerbIHNMTalkTo + 2,'t',0, 8,9,0}, + {kPanelButtonVerb, 223,44, 114,30, kVerbIHNMSwallow + 2,'s',0, 10,11,0}, + {kPanelButtonVerb, 223,76, 114,30, kVerbIHNMGive + 2,'g',0, 12,13,0}, + {kPanelButtonVerb, 223,108, 114,30, kVerbIHNMPush + 2,'p',0, 14,15,0}, {kPanelButtonArrow, 606,22, 20,25, -1,'[',0, 0,0,0}, //TODO: arrow Sprite Numbers {kPanelButtonArrow, 606,108, 20,25, 1,']',0, 0,0,0}, diff --git a/engines/saga/interface.cpp b/engines/saga/interface.cpp index 3ee9d93336..abf706310f 100644 --- a/engines/saga/interface.cpp +++ b/engines/saga/interface.cpp @@ -69,14 +69,14 @@ static int verbTypeToTextStringsIdLUT[2][kVerbTypeIdsMax] = { -1, -1}, {-1, - 3, //TODO:check - 2, - 1, - 5, - 6, //TODO:check - 8, //TODO:check - 7, - 4} + kVerbIHNMWalk, + kVerbIHNMLookAt, + kVerbIHNMTake, + kVerbIHNMUse, + kVerbIHNMTalkTo, + kVerbIHNMSwallow, + kVerbIHNMGive, + kVerbIHNMPush} }; Interface::Interface(SagaEngine *vm) : _vm(vm) { @@ -1939,7 +1939,8 @@ void Interface::drawVerbPanelText(Surface *ds, PanelButton *panelButton, KnownCo textId = verbTypeToTextStringsIdLUT[0][panelButton->id]; text = _vm->getTextString(textId); } else { - textId = verbTypeToTextStringsIdLUT[1][panelButton->id]; + // This -2 has been placed because of the changes in the ids in IHNM_MainPanelButtons + textId = verbTypeToTextStringsIdLUT[1][panelButton->id - 2]; text = _vm->_script->_mainStrings.getString(textId + 1); textShadowKnownColor = kKnownColorTransparent; } |