From 8c82d94c4072b76b48cd5ec08aefddc7e2fce702 Mon Sep 17 00:00:00 2001 From: Torbjörn Andersson Date: Wed, 8 Jun 2005 14:41:57 +0000 Subject: Allow part of the IHNM intro to run again. I haven't verified that these resource numbers are correct. svn-id: r18366 --- saga/game.cpp | 6 +++--- saga/interface.cpp | 20 +++++++++++--------- saga/resnames.h | 3 +++ 3 files changed, 17 insertions(+), 12 deletions(-) (limited to 'saga') diff --git a/saga/game.cpp b/saga/game.cpp index f4e0d67dc1..b410ec24b8 100644 --- a/saga/game.cpp +++ b/saga/game.cpp @@ -393,9 +393,9 @@ static GameResourceDescription IHNM_Resources = { RID_IHNM_SCRIPT_LUT, // Script lookup table RN RID_IHNM_MAIN_PANEL, RID_IHNM_CONVERSE_PANEL, - 0, - 0, - 0, + RID_IHNM_OPTION_PANEL, + RID_IHNM_MAIN_SPRITES, + RID_IHNM_MAIN_PANEL_SPRITES, 0, RID_IHNM_MAIN_STRINGS, 0 diff --git a/saga/interface.cpp b/saga/interface.cpp index 1189c99e58..7c490fb1f4 100644 --- a/saga/interface.cpp +++ b/saga/interface.cpp @@ -125,11 +125,14 @@ Interface::Interface(SagaEngine *vm) : _vm(vm), _initialized(false) { if (_vm->_sprite->loadList(_vm->getResourceDescription()->mainPanelSpritesResourceId, _mainPanel.sprites) != SUCCESS) { error("Interface::Interface(): Unable to load sprite list"); } - - if (_vm->_sprite->loadList(_vm->getResourceDescription()->defaultPortraitsResourceId, _defPortraits) != SUCCESS) { - error("Interface::Interface(): Unable to load sprite list"); - } + if (_vm->getGameType() == GType_ITE) { + if (_vm->_sprite->loadList(_vm->getResourceDescription()->defaultPortraitsResourceId, _defPortraits) != SUCCESS) { + error("Interface::Interface(): Unable to load sprite list"); + } + } else { + // TODO + } _mainPanel.x = _vm->getDisplayInfo().mainPanelXOffset; _mainPanel.y = _vm->getDisplayInfo().mainPanelYOffset; @@ -553,11 +556,10 @@ void Interface::draw() { if (_panelMode == kPanelMain || _panelMode == kPanelConverse || _lockedMode == kPanelMain || _lockedMode == kPanelConverse) { - leftPortraitPoint.x = _mainPanel.x + _vm->getDisplayInfo().leftPortraitXOffset; - leftPortraitPoint.y = _mainPanel.y + _vm->getDisplayInfo().leftPortraitYOffset; - _vm->_sprite->draw(backBuffer, _defPortraits, _leftPortrait, leftPortraitPoint, 256); - } - + leftPortraitPoint.x = _mainPanel.x + _vm->getDisplayInfo().leftPortraitXOffset; + leftPortraitPoint.y = _mainPanel.y + _vm->getDisplayInfo().leftPortraitYOffset; + _vm->_sprite->draw(backBuffer, _defPortraits, _leftPortrait, leftPortraitPoint, 256); + } if (!_inMainMode && _vm->getDisplayInfo().rightPortraitXOffset >= 0) { //FIXME: should we change !_inMainMode to _panelMode == kPanelConverse ? rightPortraitPoint.x = _mainPanel.x + _vm->getDisplayInfo().rightPortraitXOffset; diff --git a/saga/resnames.h b/saga/resnames.h index a3e2171ece..17290e97f4 100644 --- a/saga/resnames.h +++ b/saga/resnames.h @@ -68,6 +68,9 @@ namespace Saga { #define RID_IHNM_MAIN_PANEL 9 #define RID_IHNM_CONVERSE_PANEL 10 +#define RID_IHNM_OPTION_PANEL 11 // TODO: verify this +#define RID_IHNM_MAIN_SPRITES 12 // TODO: verify this +#define RID_IHNM_MAIN_PANEL_SPRITES 13 // TODO: verify this #define RID_IHNM_MAIN_STRINGS 21 // Puzzle portraits -- cgit v1.2.3