aboutsummaryrefslogtreecommitdiff
path: root/engines/kyra
diff options
context:
space:
mode:
Diffstat (limited to 'engines/kyra')
-rw-r--r--engines/kyra/engine/chargen.cpp74
-rw-r--r--engines/kyra/engine/darkmoon.cpp4
-rw-r--r--engines/kyra/engine/eob.cpp3
-rw-r--r--engines/kyra/engine/eob.h3
-rw-r--r--engines/kyra/engine/eobcommon.cpp9
-rw-r--r--engines/kyra/engine/kyra_rpg.h16
-rw-r--r--engines/kyra/engine/scene_eob.cpp4
-rw-r--r--engines/kyra/gui/gui_eob.cpp226
-rw-r--r--engines/kyra/gui/gui_eob.h2
-rw-r--r--engines/kyra/resource/staticres_eob.cpp19
-rw-r--r--engines/kyra/resource/staticres_lol.cpp2
-rw-r--r--engines/kyra/text/text_rpg.cpp12
12 files changed, 196 insertions, 178 deletions
diff --git a/engines/kyra/engine/chargen.cpp b/engines/kyra/engine/chargen.cpp
index 14e72f832c..7adca7f4da 100644
--- a/engines/kyra/engine/chargen.cpp
+++ b/engines/kyra/engine/chargen.cpp
@@ -357,7 +357,7 @@ void CharacterGenerator::checkForCompleteParty() {
_screen->copyRegion(0, 0, 160, 0, 160, 128, 2, 2, Screen::CR_NO_P_CHECK);
int cp = _screen->setCurPage(2);
int x = (_vm->gameFlags().platform == Common::kPlatformFMTowns) ? 184 : 168;
- _screen->printShadedText(_chargenStrings1[8], x, 16, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_chargenStrings1[8], x, 16, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->setCurPage(cp);
_screen->copyRegion(160, 0, 144, 64, 160, 128, 2, 0, Screen::CR_NO_P_CHECK);
@@ -369,7 +369,7 @@ void CharacterGenerator::checkForCompleteParty() {
if (numChars == 4) {
_screen->setCurPage(2);
- _screen->printShadedText(_chargenStrings1[0], x, 61, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_chargenStrings1[0], x, 61, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->setCurPage(0);
_screen->copyRegion(168, 61, 152, 125, 136, 40, 2, 0, Screen::CR_NO_P_CHECK);
toggleSpecialButton(15, 0, 0);
@@ -450,7 +450,7 @@ int CharacterGenerator::viewDeleteCharacter() {
if (_characters[_activeBox].name[0]) {
processSpecialButton(16);
_characters[_activeBox].name[0] = 0;
- processNameInput(_activeBox, _vm->guiSettings()->colors.menuTxtColBlack);
+ processNameInput(_activeBox, _vm->guiSettings()->colors.guiColorBlack);
processFaceMenuSelection(_activeBox + 50);
}
} else {
@@ -511,10 +511,10 @@ void CharacterGenerator::createPartyMember() {
for (_characters[_activeBox].name[0] = 0; _characters[_activeBox].name[0] == 0 && !_vm->shouldQuit();) {
processFaceMenuSelection(_chargenMinStats[6]);
printStats(_activeBox, 0);
- _screen->printShadedText(_chargenStrings2[11], 149, 100, _vm->guiSettings()->colors.menuTxtColLightBlue, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_chargenStrings2[11], 149, 100, _vm->guiSettings()->colors.guiColorLightBlue, 0, _vm->guiSettings()->colors.guiColorBlack);
if (!_vm->shouldQuit()) {
- _vm->_gui->getTextInput(_characters[_activeBox].name, 24, 100, 10, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColDarkRed);
- processNameInput(_activeBox, _vm->guiSettings()->colors.menuTxtColBlue);
+ _vm->_gui->getTextInput(_characters[_activeBox].name, 24, 100, 10, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorDarkRed);
+ processNameInput(_activeBox, _vm->guiSettings()->colors.guiColorBlue);
}
}
}
@@ -523,7 +523,7 @@ void CharacterGenerator::createPartyMember() {
int CharacterGenerator::raceSexMenu() {
_screen->drawBox(_chargenBoxX[_activeBox], _chargenBoxY[_activeBox], _chargenBoxX[_activeBox] + 32, _chargenBoxY[_activeBox] + 33, 12);
_screen->copyRegion(0, 0, 144, 64, 160, 128, 2, 0, Screen::CR_NO_P_CHECK);
- _screen->printShadedText(_chargenStrings2[8], 147, 67, _vm->guiSettings()->colors.menuTxtColLightBlue, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_chargenStrings2[8], 147, 67, _vm->guiSettings()->colors.guiColorLightBlue, 0, _vm->guiSettings()->colors.guiColorBlack);
_vm->removeInputTop();
_vm->_gui->simpleMenu_setup(1, 0, _chargenRaceSexStrings, -1, 0, 0);
@@ -550,7 +550,7 @@ int CharacterGenerator::classMenu(int raceSex) {
updateMagicShapes();
_screen->copyRegion(0, 0, 144, 64, 160, 128, 2, 0, Screen::CR_NO_P_CHECK);
- _screen->printShadedText(_chargenStrings2[9], 147, 67, _vm->guiSettings()->colors.menuTxtColLightBlue, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_chargenStrings2[9], 147, 67, _vm->guiSettings()->colors.guiColorLightBlue, 0, _vm->guiSettings()->colors.guiColorBlack);
toggleSpecialButton(5, 0, 0);
@@ -598,7 +598,7 @@ int CharacterGenerator::alignmentMenu(int cClass) {
updateMagicShapes();
_screen->copyRegion(0, 0, 144, 64, 160, 128, 2, 0, Screen::CR_NO_P_CHECK);
- _screen->printShadedText(_chargenStrings2[10], 147, 67, _vm->guiSettings()->colors.menuTxtColLightBlue, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_chargenStrings2[10], 147, 67, _vm->guiSettings()->colors.guiColorLightBlue, 0, _vm->guiSettings()->colors.guiColorBlack);
toggleSpecialButton(5, 0, 0);
@@ -923,24 +923,24 @@ void CharacterGenerator::printStats(int index, int mode) {
if (mode != 4)
_screen->drawShape(2, c->faceShape, 224, 2, 0);
- _screen->printShadedText(c->name, 160 + ((160 - _screen->getTextWidth(c->name)) / 2), 35, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
- _screen->printShadedText(_chargenRaceSexStrings[c->raceSex], 160 + ((20 - strlen(_chargenRaceSexStrings[c->raceSex])) << 2), 45, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
- _screen->printShadedText(_chargenClassStrings[c->cClass], 160 + ((20 - strlen(_chargenClassStrings[c->cClass])) << 2), 54, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(c->name, 160 + ((160 - _screen->getTextWidth(c->name)) / 2), 35, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
+ _screen->printShadedText(_chargenRaceSexStrings[c->raceSex], 160 + ((20 - strlen(_chargenRaceSexStrings[c->raceSex])) << 2), 45, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
+ _screen->printShadedText(_chargenClassStrings[c->cClass], 160 + ((20 - strlen(_chargenClassStrings[c->cClass])) << 2), 54, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
for (int i = 0; i < 6; i++)
- _screen->printShadedText(_chargenStatStrings[i], 163, (i + 8) << 3, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_chargenStatStrings[i], 163, (i + 8) << 3, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
- _screen->printShadedText(_chargenStrings1[2], 248, 64, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_chargenStrings1[2], 248, 64, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
Common::String str = Common::String::format(_chargenStrings1[3], _vm->getCharStrength(c->strengthCur, c->strengthExtCur).c_str(), c->intelligenceCur, c->wisdomCur, c->dexterityCur, c->constitutionCur, c->charismaCur);
- _screen->printShadedText(str.c_str(), 192, 64, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(str.c_str(), 192, 64, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
str = Common::String::format(_chargenStrings1[4], c->armorClass, c->hitPointsMax);
- _screen->printShadedText(str.c_str(), 280, 64, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(str.c_str(), 280, 64, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
const char *lvlStr = c->level[2] ? _chargenStrings1[7] : (c->level[1] ? _chargenStrings1[6] : _chargenStrings1[5]);
str = Common::String::format(lvlStr, c->level[0], c->level[1], c->level[2]);
- _screen->printShadedText(str.c_str(), 280, 80, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(str.c_str(), 280, 80, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
switch (mode) {
case 1:
@@ -975,7 +975,7 @@ void CharacterGenerator::printStats(int index, int mode) {
void CharacterGenerator::processNameInput(int index, int textColor) {
Screen::FontId of = _screen->setFont(Screen::FID_6_FNT);
- _screen->fillRect(_chargenNameFieldX[index], _chargenNameFieldY[index], _chargenNameFieldX[index] + 59, _chargenNameFieldY[index] + 5, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->fillRect(_chargenNameFieldX[index], _chargenNameFieldY[index], _chargenNameFieldX[index] + 59, _chargenNameFieldY[index] + 5, _vm->guiSettings()->colors.guiColorBlack);
int xOffs = (60 - _screen->getTextWidth(_characters[index].name)) >> 1;
_screen->printText(_characters[index].name, _chargenNameFieldX[index] + xOffs, _chargenNameFieldY[index], textColor, 0);
_screen->updateScreen();
@@ -1010,7 +1010,7 @@ int CharacterGenerator::modifyStat(int index, int8 *stat1, int8 *stat2) {
Common::String statStr = index ? Common::String::format("%d", *s1) : _vm->getCharStrength(*s1, *s2);
_screen->copyRegion(b->x - 112, b->y - 64, b->x + 32, b->y, 40, b->height, 2, 0, Screen::CR_NO_P_CHECK);
- _screen->printShadedText(statStr.c_str(), b->x + 32, b->y, _vm->guiSettings()->colors.menuTxtColLightRed, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(statStr.c_str(), b->x + 32, b->y, _vm->guiSettings()->colors.guiColorLightRed, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->updateScreen();
EoBCharacter *c = &_characters[_activeBox];
@@ -1089,7 +1089,7 @@ int CharacterGenerator::modifyStat(int index, int8 *stat1, int8 *stat2) {
statStr = index ? Common::String::format("%d", *s1) : _vm->getCharStrength(*s1, *s2);
_screen->copyRegion(b->x - 112, b->y - 64, b->x + 32, b->y, 40, b->height, 2, 0, Screen::CR_NO_P_CHECK);
- _screen->printShadedText(statStr.c_str(), b->x + 32, b->y, _vm->guiSettings()->colors.menuTxtColLightRed, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(statStr.c_str(), b->x + 32, b->y, _vm->guiSettings()->colors.guiColorLightRed, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->updateScreen();
if (index == 4) {
@@ -1101,7 +1101,7 @@ int CharacterGenerator::modifyStat(int index, int8 *stat1, int8 *stat2) {
if (c->hitPointsCur != oldVal) {
statStr = Common::String::format("%d", c->hitPointsCur);
_screen->copyRegion(120, 72, 264, 136, 40, 8, 2, 0, Screen::CR_NO_P_CHECK);
- _screen->printShadedText(statStr.c_str(), 264, 136, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(statStr.c_str(), 264, 136, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->updateScreen();
}
@@ -1112,14 +1112,14 @@ int CharacterGenerator::modifyStat(int index, int8 *stat1, int8 *stat2) {
if (c->armorClass != oldVal) {
statStr = Common::String::format("%d", c->armorClass);
_screen->copyRegion(120, 64, 264, 128, 40, 8, 2, 0, Screen::CR_NO_P_CHECK);
- _screen->printShadedText(statStr.c_str(), 264, 128, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(statStr.c_str(), 264, 128, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->updateScreen();
}
}
if (loop == false) {
statStr = index ? Common::String::format("%d", *s1) : _vm->getCharStrength(*s1, *s2);
- _screen->printText(statStr.c_str(), b->x + 32, b->y, _vm->guiSettings()->colors.menuTxtColWhite, 0);
+ _screen->printText(statStr.c_str(), b->x + 32, b->y, _vm->guiSettings()->colors.guiColorWhite, 0);
_screen->updateScreen();
}
}
@@ -1172,7 +1172,7 @@ int CharacterGenerator::getMinHp(int cclass, int constitution, int level1, int l
void CharacterGenerator::finish() {
_screen->copyRegion(0, 0, 160, 0, 160, 128, 2, 2, Screen::CR_NO_P_CHECK);
int cp = _screen->setCurPage(2);
- _screen->printShadedText(_chargenEnterGameStrings[0], (_vm->gameFlags().platform == Common::kPlatformFMTowns) ? 184 : 168, 32, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_chargenEnterGameStrings[0], (_vm->gameFlags().platform == Common::kPlatformFMTowns) ? 184 : 168, 32, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->setCurPage(cp);
_screen->copyRegion(160, 0, 144, 64, 160, 128, 2, 0, Screen::CR_NO_P_CHECK);
_screen->updateScreen();
@@ -1631,8 +1631,8 @@ int TransferPartyWiz::selectCharactersMenu() {
_screen->clearCurPage();
_vm->gui_drawBox(0, 0, 320, 163, _vm->guiSettings()->colors.frame1, _vm->guiSettings()->colors.frame2, _vm->guiSettings()->colors.fill);
- _screen->printText(_strings2[0], 5, 3, _vm->guiSettings()->colors.menuTxtColWhite, 0);
- _screen->printText(_strings2[1], 5, 10, _vm->guiSettings()->colors.menuTxtColWhite, 0);
+ _screen->printText(_strings2[0], 5, 3, _vm->guiSettings()->colors.guiColorWhite, 0);
+ _screen->printText(_strings2[1], 5, 10, _vm->guiSettings()->colors.guiColorWhite, 0);
for (int i = 0; i < 6; i++)
drawCharPortraitWithStats(i, 0);
@@ -1640,8 +1640,8 @@ int TransferPartyWiz::selectCharactersMenu() {
_vm->gui_drawBox(4, 148, 43, 12, _vm->guiSettings()->colors.frame1, _vm->guiSettings()->colors.frame2, _vm->guiSettings()->colors.fill);
_vm->gui_drawBox(272, 148, 43, 12, _vm->guiSettings()->colors.frame1, _vm->guiSettings()->colors.frame2, _vm->guiSettings()->colors.fill);
- _screen->printShadedText(_labels[0], 9, 151, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
- _screen->printShadedText(_labels[1], 288, 151, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_labels[0], 9, 151, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
+ _screen->printShadedText(_labels[1], 288, 151, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->setCurPage(0);
_screen->copyRegion(0, 0, 0, 0, 320, 200, 2, 0, Screen::CR_NO_P_CHECK);
@@ -1720,7 +1720,7 @@ int TransferPartyWiz::selectCharactersMenu() {
if (count == 4 || _vm->shouldQuit())
loop = false;
else
- _vm->_gui->messageDialogue(16, count < 4 ? 69 : 70, _vm->guiSettings()->colors.menuTxtColLightRed);
+ _vm->_gui->messageDialogue(16, count < 4 ? 69 : 70, _vm->guiSettings()->colors.guiColorLightRed);
_screen->updateScreen();
}
@@ -1729,7 +1729,7 @@ int TransferPartyWiz::selectCharactersMenu() {
if (_vm->shouldQuit())
return 0;
else
- _vm->_gui->messageDialogue(16, 71, _vm->guiSettings()->colors.menuTxtColLightRed);
+ _vm->_gui->messageDialogue(16, 71, _vm->guiSettings()->colors.guiColorLightRed);
return selection;
}
@@ -1747,17 +1747,17 @@ void TransferPartyWiz::drawCharPortraitWithStats(int charIndex, bool enabled) {
_screen->drawShape(_screen->_curPage, c->faceShape, x + 4, y + 25, 0);
- int color1 = _vm->guiSettings()->colors.menuTxtColWhite;
- int color2 = _vm->guiSettings()->colors.menuTxtColBlack;
+ int color1 = _vm->guiSettings()->colors.guiColorWhite;
+ int color2 = _vm->guiSettings()->colors.guiColorBlack;
if (enabled) {
- color1 = _vm->guiSettings()->colors.menuTxtColLightRed;
- color2 = _vm->guiSettings()->colors.menuTxtColWhite;
+ color1 = _vm->guiSettings()->colors.guiColorLightRed;
+ color2 = _vm->guiSettings()->colors.guiColorWhite;
} else {
_screen->drawShape(_screen->_curPage, _vm->_disabledCharGrid, x + 4, y + 25, 0);
}
- _screen->printShadedText(c->name, x + 44, y + 27, color1, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(c->name, x + 44, y + 27, color1, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->printText(_vm->_chargenRaceSexStrings[c->raceSex], x + 43, y + 36, color2, 0);
_screen->printText(_vm->_chargenClassStrings[c->cClass], x + 43, y + 43, color2, 0);
@@ -1770,7 +1770,7 @@ void TransferPartyWiz::drawCharPortraitWithStats(int charIndex, bool enabled) {
void TransferPartyWiz::updateHighlight(int index) {
static const int16 xPos[] = { 9, 288 };
if (_highlight > 5 && _highlight != index)
- _screen->printText(_labels[_highlight - 6], xPos[_highlight - 6], 151, _vm->guiSettings()->colors.menuTxtColWhite, 0);
+ _screen->printText(_labels[_highlight - 6], xPos[_highlight - 6], 151, _vm->guiSettings()->colors.guiColorWhite, 0);
if (index < 6) {
_vm->_gui->updateBoxFrameHighLight(14 + index);
@@ -1784,7 +1784,7 @@ void TransferPartyWiz::updateHighlight(int index) {
if (_highlight < 6)
_vm->_gui->updateBoxFrameHighLight(-1);
- _screen->printText(_labels[index - 6], xPos[index - 6], 151, _vm->guiSettings()->colors.menuTxtColLightRed, 0);
+ _screen->printText(_labels[index - 6], xPos[index - 6], 151, _vm->guiSettings()->colors.guiColorLightRed, 0);
_screen->updateScreen();
_highlight = index;
}
diff --git a/engines/kyra/engine/darkmoon.cpp b/engines/kyra/engine/darkmoon.cpp
index e3b151b05d..d8cb1254d5 100644
--- a/engines/kyra/engine/darkmoon.cpp
+++ b/engines/kyra/engine/darkmoon.cpp
@@ -395,8 +395,8 @@ void DarkMoonEngine::restParty_npc() {
gui_drawBox(_screen->_curDim->sx << 3, _screen->_curDim->sy, _screen->_curDim->w << 3, _screen->_curDim->h, guiSettings()->colors.frame1, guiSettings()->colors.frame2, -1);
gui_drawBox((_screen->_curDim->sx << 3) + 1, _screen->_curDim->sy + 1, (_screen->_curDim->w << 3) - 2, _screen->_curDim->h - 2, guiSettings()->colors.frame1, guiSettings()->colors.frame2, guiSettings()->colors.fill);
_screen->set16bitShadingLevel(0);
- _gui->messageDialogue2(11, 63, guiSettings()->colors.menuTxtColLightRed);
- _gui->messageDialogue2(11, 64, guiSettings()->colors.menuTxtColLightRed);
+ _gui->messageDialogue2(11, 63, guiSettings()->colors.guiColorLightRed);
+ _gui->messageDialogue2(11, 64, guiSettings()->colors.guiColorLightRed);
}
bool DarkMoonEngine::restParty_extraAbortCondition() {
diff --git a/engines/kyra/engine/eob.cpp b/engines/kyra/engine/eob.cpp
index 3a83643f19..8c59d4de0c 100644
--- a/engines/kyra/engine/eob.cpp
+++ b/engines/kyra/engine/eob.cpp
@@ -42,6 +42,7 @@ EoBEngine::EoBEngine(OSystem *system, const GameFlags &flags)
_dscDoorY4 = _dscDoorY5 = _dscDoorY6 = _dscDoorY7 = _doorShapeEncodeDefs = 0;
_doorSwitchShapeEncodeDefs = _doorSwitchCoords = 0;
_dscDoorCoordsExt = 0;
+ _useMainMenuGUISettings = false;
}
EoBEngine::~EoBEngine() {
@@ -569,7 +570,7 @@ void EoBEngine::healParty() {
const KyraRpgGUISettings *EoBEngine::guiSettings() const {
if (_flags.platform == Common::kPlatformAmiga)
- return &_guiSettingsAmiga;
+ return _useMainMenuGUISettings ? &_guiSettingsAmigaMainMenu : &_guiSettingsAmiga;
else if (_configRenderMode == Common::kRenderCGA || _configRenderMode == Common::kRenderEGA)
return &_guiSettingsEGA;
else
diff --git a/engines/kyra/engine/eob.h b/engines/kyra/engine/eob.h
index 896f332047..d0a1c01aeb 100644
--- a/engines/kyra/engine/eob.h
+++ b/engines/kyra/engine/eob.h
@@ -112,11 +112,14 @@ private:
void healParty();
const KyraRpgGUISettings *guiSettings() const;
+ void useMainMenuGUISettings(bool toggle) { _useMainMenuGUISettings = toggle; }
static const KyraRpgGUISettings _guiSettingsVGA;
static const KyraRpgGUISettings _guiSettingsEGA;
static const KyraRpgGUISettings _guiSettingsAmiga;
+ static const KyraRpgGUISettings _guiSettingsAmigaMainMenu;
static const uint8 _egaDefaultPalette[];
+ bool _useMainMenuGUISettings;
};
} // End of namespace Kyra
diff --git a/engines/kyra/engine/eobcommon.cpp b/engines/kyra/engine/eobcommon.cpp
index 456282c23a..a184b7ff3e 100644
--- a/engines/kyra/engine/eobcommon.cpp
+++ b/engines/kyra/engine/eobcommon.cpp
@@ -539,7 +539,7 @@ Common::Error EoBCoreEngine::init() {
_monsterFlashOverlay = new uint8[16];
_monsterStoneOverlay = new uint8[16];
- memset(_monsterFlashOverlay, (_configRenderMode == Common::kRenderCGA) ? 0xFF : 0x0F, 16 * sizeof(uint8));
+ memset(_monsterFlashOverlay, (_configRenderMode == Common::kRenderCGA) ? 0xFF : guiSettings()->colors.guiColorWhite, 16 * sizeof(uint8));
memset(_monsterStoneOverlay, 0x0D, 16 * sizeof(uint8));
_monsterFlashOverlay[0] = _monsterStoneOverlay[0] = 0;
@@ -586,8 +586,7 @@ Common::Error EoBCoreEngine::go() {
if (action == -1) {
// load game
startupLoad();
- repeatLoop = _gui->runLoadMenu(72, 14);
- //if (!repeatLoop && !shouldQuit())
+ repeatLoop = _gui->runLoadMenu(72, 14, true);
} else if (action == -2) {
// new game
@@ -1900,11 +1899,11 @@ bool EoBCoreEngine::checkPassword() {
const uint8 *shp = (_mnDef[c << 2] < _numLargeItemShapes) ? _largeItemShapes[_mnDef[c << 2]] : (_mnDef[c << 2] < 15 ? 0 : _smallItemShapes[_mnDef[c << 2] - 15]);
assert(shp);
_screen->drawShape(0, shp, 100, 2, 13);
- _screen->printShadedText(Common::String::format(_mnPrompt[0], _mnDef[(c << 2) + 1], _mnDef[(c << 2) + 2]).c_str(), (_screen->_curDim->sx + 1) << 3, _screen->_curDim->sy, guiSettings()->colors.menuTxtColWhite, guiSettings()->colors.fill, guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(Common::String::format(_mnPrompt[0], _mnDef[(c << 2) + 1], _mnDef[(c << 2) + 2]).c_str(), (_screen->_curDim->sx + 1) << 3, _screen->_curDim->sy, guiSettings()->colors.guiColorWhite, guiSettings()->colors.fill, guiSettings()->colors.guiColorBlack);
memset(answ, 0, 20);
gui_drawBox(76, 100, 133, 14, guiSettings()->colors.frame2, guiSettings()->colors.frame1, -1);
gui_drawBox(77, 101, 131, 12, guiSettings()->colors.frame2, guiSettings()->colors.frame1, -1);
- if (_gui->getTextInput(answ, 10, 103, 15, guiSettings()->colors.menuTxtColWhite, guiSettings()->colors.fill, guiSettings()->colors.menuTxtColDarkRed) < 0)
+ if (_gui->getTextInput(answ, 10, 103, 15, guiSettings()->colors.guiColorWhite, guiSettings()->colors.fill, guiSettings()->colors.guiColorDarkRed) < 0)
i = 3;
if (!scumm_stricmp(_mnWord[c], answ))
break;
diff --git a/engines/kyra/engine/kyra_rpg.h b/engines/kyra/engine/kyra_rpg.h
index 13853fb296..a132ec7419 100644
--- a/engines/kyra/engine/kyra_rpg.h
+++ b/engines/kyra/engine/kyra_rpg.h
@@ -112,12 +112,15 @@ struct KyraRpgGUISettings {
uint8 inactiveTabFrame2;
int inactiveTabFill;
- uint8 menuTxtColWhite;
- uint8 menuTxtColLightRed;
- uint8 menuTxtColDarkRed;
- uint8 menuTxtColLightBlue;
- uint8 menuTxtColBlue;
- uint8 menuTxtColBlack;
+ uint8 guiColorWhite;
+ uint8 guiColorLightRed;
+ uint8 guiColorDarkRed;
+ uint8 guiColorLightBlue;
+ uint8 guiColorBlue;
+ uint8 guiColorYellow;
+ uint8 guiColorLightGreen;
+ uint8 guiColorDarkGreen;
+ uint8 guiColorBlack;
} colors;
};
@@ -335,6 +338,7 @@ protected:
bool clickedShape(int shapeIndex);
virtual const KyraRpgGUISettings *guiSettings() const = 0;
+ virtual void useMainMenuGUISettings(bool toggle) {};
int _clickedShapeXOffs;
int _clickedShapeYOffs;
diff --git a/engines/kyra/engine/scene_eob.cpp b/engines/kyra/engine/scene_eob.cpp
index 0bd4ca9072..aebb8ae388 100644
--- a/engines/kyra/engine/scene_eob.cpp
+++ b/engines/kyra/engine/scene_eob.cpp
@@ -93,8 +93,8 @@ void EoBCoreEngine::loadLevel(int level, int sub) {
loadVcnData(gfxFile.c_str(), (_flags.gameID == GI_EOB1 && _flags.platform == Common::kPlatformDOS) ? _cgaMappingLevel[_cgaLevelMappingIndex[level - 1]] : 0);
_screen->loadEoBBitmap("INVENT", _cgaMappingInv, 5, 3, 2);
- if (_flags.platform == Common::kPlatformAmiga)
- _screen->setScreenPalette(_screen->getPalette(0));
+ //if (_flags.platform == Common::kPlatformAmiga)
+ // _screen->setScreenPalette(_screen->getPalette(0));
delayUntil(end);
snd_stopSound();
diff --git a/engines/kyra/gui/gui_eob.cpp b/engines/kyra/gui/gui_eob.cpp
index bfe338bccb..f521b9b757 100644
--- a/engines/kyra/gui/gui_eob.cpp
+++ b/engines/kyra/gui/gui_eob.cpp
@@ -83,12 +83,12 @@ void EoBCoreEngine::gui_drawCharPortraitWithStats(int index) {
static const uint16 charPortraitPosY[] = { 2, 54, 106 };
EoBCharacter *c = &_characters[index];
- int txtCol1 = guiSettings()->colors.menuTxtColBlack;
- int txtCol2 = guiSettings()->colors.menuTxtColWhite;
+ int txtCol1 = guiSettings()->colors.guiColorBlack;
+ int txtCol2 = guiSettings()->colors.guiColorWhite;
if ((_flags.gameID == GI_EOB1 && c->flags & 6) || (_flags.gameID == GI_EOB2 && c->flags & 0x0E)) {
- txtCol1 = guiSettings()->colors.menuTxtColDarkRed;
- txtCol2 = guiSettings()->colors.menuTxtColLightRed;
+ txtCol1 = guiSettings()->colors.guiColorDarkRed;
+ txtCol2 = guiSettings()->colors.guiColorLightRed;
}
if (_currentControlMode == 0) {
@@ -101,7 +101,7 @@ void EoBCoreEngine::gui_drawCharPortraitWithStats(int index) {
int cp = _screen->setCurPage(2);
if (index == _exchangeCharacterId)
- _screen->printText(_characterGuiStringsSt[0], x2 + 2, y2 + 2, guiSettings()->colors.menuTxtColDarkRed, guiSettings()->colors.fill);
+ _screen->printText(_characterGuiStringsSt[0], x2 + 2, y2 + 2, guiSettings()->colors.guiColorDarkRed, guiSettings()->colors.fill);
else
_screen->printText(c->name, x2 + 2, y2 + (_flags.platform == Common::kPlatformFMTowns ? 1 : 2), txtCol1, guiSettings()->colors.fill);
@@ -116,7 +116,7 @@ void EoBCoreEngine::gui_drawCharPortraitWithStats(int index) {
if (c->damageTaken > 0) {
_screen->drawShape(2, _redSplatShape, x2 + 13, y2 + 30, 0);
Common::String tmpStr = Common::String::format("%d", c->damageTaken);
- _screen->printText(tmpStr.c_str(), x2 + 34 - tmpStr.size() * 3, y2 + 42, (_configRenderMode == Common::kRenderCGA) ? 12 : guiSettings()->colors.menuTxtColWhite, 0);
+ _screen->printText(tmpStr.c_str(), x2 + 34 - tmpStr.size() * 3, y2 + 42, (_configRenderMode == Common::kRenderCGA) ? 12 : guiSettings()->colors.guiColorWhite, 0);
}
_screen->setCurPage(cp);
@@ -130,23 +130,23 @@ void EoBCoreEngine::gui_drawCharPortraitWithStats(int index) {
_screen->copyRegion(176, 0, 0, 0, 144, 168, 2, 2, Screen::CR_NO_P_CHECK);
_screen->_curPage = 2;
gui_drawFaceShape(index);
- _screen->printShadedText(c->name, 219, 6, txtCol2, 0, guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(c->name, 219, 6, txtCol2, 0, guiSettings()->colors.guiColorBlack);
gui_drawHitpoints(index);
gui_drawFoodStatusGraph(index);
if (_currentControlMode == 1) {
if (c->hitPointsCur == -10)
- _screen->printShadedText(_characterGuiStringsSt[1], 247, 158, guiSettings()->colors.menuTxtColLightRed, guiSettings()->colors.sfill, guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_characterGuiStringsSt[1], 247, 158, guiSettings()->colors.guiColorLightRed, guiSettings()->colors.sfill, guiSettings()->colors.guiColorBlack);
else if (c->hitPointsCur < 1)
- _screen->printShadedText(_characterGuiStringsSt[2], 226, 158, guiSettings()->colors.menuTxtColLightRed, guiSettings()->colors.sfill, guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_characterGuiStringsSt[2], 226, 158, guiSettings()->colors.guiColorLightRed, guiSettings()->colors.sfill, guiSettings()->colors.guiColorBlack);
else if (c->effectFlags & 0x2000)
- _screen->printShadedText(_characterGuiStringsSt[3], 220, 158, guiSettings()->colors.menuTxtColLightRed, guiSettings()->colors.sfill, guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_characterGuiStringsSt[3], 220, 158, guiSettings()->colors.guiColorLightRed, guiSettings()->colors.sfill, guiSettings()->colors.guiColorBlack);
else if (c->flags & 2)
- _screen->printShadedText(_characterGuiStringsSt[4], 235, 158, guiSettings()->colors.menuTxtColLightRed, guiSettings()->colors.sfill, guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_characterGuiStringsSt[4], 235, 158, guiSettings()->colors.guiColorLightRed, guiSettings()->colors.sfill, guiSettings()->colors.guiColorBlack);
else if (c->flags & 4)
- _screen->printShadedText(_characterGuiStringsSt[5], 232, 158, guiSettings()->colors.menuTxtColLightRed, guiSettings()->colors.sfill, guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_characterGuiStringsSt[5], 232, 158, guiSettings()->colors.guiColorLightRed, guiSettings()->colors.sfill, guiSettings()->colors.guiColorBlack);
else if (c->flags & 8)
- _screen->printShadedText(_characterGuiStringsSt[6], 232, 158, guiSettings()->colors.menuTxtColLightRed, guiSettings()->colors.sfill, guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_characterGuiStringsSt[6], 232, 158, guiSettings()->colors.guiColorLightRed, guiSettings()->colors.sfill, guiSettings()->colors.guiColorBlack);
for (int i = 0; i < 27; i++)
gui_drawInventoryItem(i, 0, 2);
@@ -161,36 +161,36 @@ void EoBCoreEngine::gui_drawCharPortraitWithStats(int index) {
for (int i = 0; i < 3; i++)
_screen->fillRect(cm2X1[i], cm2Y1[i], cm2X2[i], cm2Y2[i], guiSettings()->colors.sfill);
- _screen->printShadedText(_characterGuiStringsIn[0], 183, 42, guiSettings()->colors.menuTxtColWhite, guiSettings()->colors.sfill, guiSettings()->colors.menuTxtColBlack);
- _screen->printText(_chargenClassStrings[c->cClass], 183, 55, guiSettings()->colors.menuTxtColBlack, guiSettings()->colors.sfill);
- _screen->printText(_chargenAlignmentStrings[c->alignment], 183, 62, guiSettings()->colors.menuTxtColBlack, guiSettings()->colors.sfill);
- _screen->printText(_chargenRaceSexStrings[c->raceSex], 183, 69, guiSettings()->colors.menuTxtColBlack, guiSettings()->colors.sfill);
+ _screen->printShadedText(_characterGuiStringsIn[0], 183, 42, guiSettings()->colors.guiColorWhite, guiSettings()->colors.sfill, guiSettings()->colors.guiColorBlack);
+ _screen->printText(_chargenClassStrings[c->cClass], 183, 55, guiSettings()->colors.guiColorBlack, guiSettings()->colors.sfill);
+ _screen->printText(_chargenAlignmentStrings[c->alignment], 183, 62, guiSettings()->colors.guiColorBlack, guiSettings()->colors.sfill);
+ _screen->printText(_chargenRaceSexStrings[c->raceSex], 183, 69, guiSettings()->colors.guiColorBlack, guiSettings()->colors.sfill);
for (int i = 0; i < 6; i++)
- _screen->printText(_chargenStatStrings[6 + i], 183, 82 + i * 7, guiSettings()->colors.menuTxtColBlack, guiSettings()->colors.sfill);
+ _screen->printText(_chargenStatStrings[6 + i], 183, 82 + i * 7, guiSettings()->colors.guiColorBlack, guiSettings()->colors.sfill);
- _screen->printText(_characterGuiStringsIn[1], 183, 124, guiSettings()->colors.menuTxtColBlack, guiSettings()->colors.sfill);
- _screen->printText(_characterGuiStringsIn[2], 239, 138, guiSettings()->colors.menuTxtColBlack, guiSettings()->colors.sfill);
- _screen->printText(_characterGuiStringsIn[3], 278, 138, guiSettings()->colors.menuTxtColBlack, guiSettings()->colors.sfill);
+ _screen->printText(_characterGuiStringsIn[1], 183, 124, guiSettings()->colors.guiColorBlack, guiSettings()->colors.sfill);
+ _screen->printText(_characterGuiStringsIn[2], 239, 138, guiSettings()->colors.guiColorBlack, guiSettings()->colors.sfill);
+ _screen->printText(_characterGuiStringsIn[3], 278, 138, guiSettings()->colors.guiColorBlack, guiSettings()->colors.sfill);
- _screen->printText(getCharStrength(c->strengthCur, c->strengthExtCur).c_str(), 275, 82, guiSettings()->colors.menuTxtColWhite, guiSettings()->colors.sfill);
- _screen->printText(Common::String::format("%d", c->intelligenceCur).c_str(), 275, 89, guiSettings()->colors.menuTxtColWhite, guiSettings()->colors.sfill);
- _screen->printText(Common::String::format("%d", c->wisdomCur).c_str(), 275, 96, guiSettings()->colors.menuTxtColWhite, guiSettings()->colors.sfill);
- _screen->printText(Common::String::format("%d", c->dexterityCur).c_str(), 275, 103, guiSettings()->colors.menuTxtColWhite, guiSettings()->colors.sfill);
- _screen->printText(Common::String::format("%d", c->constitutionCur).c_str(), 275, 110, guiSettings()->colors.menuTxtColWhite, guiSettings()->colors.sfill);
- _screen->printText(Common::String::format("%d", c->charismaCur).c_str(), 275, 117, guiSettings()->colors.menuTxtColWhite, guiSettings()->colors.sfill);
- _screen->printText(Common::String::format("%d", c->armorClass).c_str(), 275, 124, guiSettings()->colors.menuTxtColWhite, guiSettings()->colors.sfill);
+ _screen->printText(getCharStrength(c->strengthCur, c->strengthExtCur).c_str(), 275, 82, guiSettings()->colors.guiColorWhite, guiSettings()->colors.sfill);
+ _screen->printText(Common::String::format("%d", c->intelligenceCur).c_str(), 275, 89, guiSettings()->colors.guiColorWhite, guiSettings()->colors.sfill);
+ _screen->printText(Common::String::format("%d", c->wisdomCur).c_str(), 275, 96, guiSettings()->colors.guiColorWhite, guiSettings()->colors.sfill);
+ _screen->printText(Common::String::format("%d", c->dexterityCur).c_str(), 275, 103, guiSettings()->colors.guiColorWhite, guiSettings()->colors.sfill);
+ _screen->printText(Common::String::format("%d", c->constitutionCur).c_str(), 275, 110, guiSettings()->colors.guiColorWhite, guiSettings()->colors.sfill);
+ _screen->printText(Common::String::format("%d", c->charismaCur).c_str(), 275, 117, guiSettings()->colors.guiColorWhite, guiSettings()->colors.sfill);
+ _screen->printText(Common::String::format("%d", c->armorClass).c_str(), 275, 124, guiSettings()->colors.guiColorWhite, guiSettings()->colors.sfill);
for (int i = 0; i < 3; i++) {
int t = getCharacterClassType(c->cClass, i);
if (t == -1)
continue;
- _screen->printText(_chargenClassStrings[t + 15], 180, 145 + 7 * i, guiSettings()->colors.menuTxtColBlack, guiSettings()->colors.sfill);
+ _screen->printText(_chargenClassStrings[t + 15], 180, 145 + 7 * i, guiSettings()->colors.guiColorBlack, guiSettings()->colors.sfill);
Common::String tmpStr = Common::String::format("%d", c->experience[i]);
- _screen->printText(tmpStr.c_str(), 251 - tmpStr.size() * 3, 145 + 7 * i, guiSettings()->colors.menuTxtColWhite, guiSettings()->colors.sfill);
+ _screen->printText(tmpStr.c_str(), 251 - tmpStr.size() * 3, 145 + 7 * i, guiSettings()->colors.guiColorWhite, guiSettings()->colors.sfill);
tmpStr = Common::String::format("%d", c->level[i]);
- _screen->printText(tmpStr.c_str(), 286 - tmpStr.size() * 3, 145 + 7 * i, guiSettings()->colors.menuTxtColWhite, guiSettings()->colors.sfill);
+ _screen->printText(tmpStr.c_str(), 286 - tmpStr.size() * 3, 145 + 7 * i, guiSettings()->colors.guiColorWhite, guiSettings()->colors.sfill);
}
}
@@ -323,7 +323,7 @@ void EoBCoreEngine::gui_drawWeaponSlotStatus(int x, int y, int status) {
break;
}
- int textColor = (_configRenderMode == Common::kRenderCGA) ? 2 : guiSettings()->colors.menuTxtColWhite;
+ int textColor = (_configRenderMode == Common::kRenderCGA) ? 2 : guiSettings()->colors.guiColorWhite;
if (!tmpStr2.empty()) {
_screen->printText(tmpStr.c_str(), x + (16 - tmpStr.size() * 3), y + 2, textColor, 0);
@@ -342,14 +342,12 @@ void EoBCoreEngine::gui_drawHitpoints(int index) {
static const uint8 xCoords[] = { 23, 95 };
static const uint8 yCoords[] = { 46, 98, 150 };
- static const uint8 barColorDefault[] = { 3, 5, 8 };
- static const uint8 barColorAmiga[] = { 27, 7, 25 };
- const uint8 *barColor = (_flags.platform == Common::kPlatformAmiga) ? barColorAmiga : barColorDefault;
int x = xCoords[index & 1];
int y = yCoords[index >> 1];
int w = 38;
int h = 3;
+ uint8 bgCol = guiSettings()->colors.fill;
if (!_screen->_curPage)
x += 176;
@@ -359,6 +357,8 @@ void EoBCoreEngine::gui_drawHitpoints(int index) {
y = 16;
w = 51;
h = 5;
+ if (_flags.platform == Common::kPlatformAmiga)
+ bgCol = guiSettings()->colors.sfill;
}
EoBCharacter *c = &_characters[index];
@@ -366,15 +366,15 @@ void EoBCoreEngine::gui_drawHitpoints(int index) {
if (_configHpBarGraphs) {
int bgCur = c->hitPointsCur + 10;
int bgMax = c->hitPointsMax + 10;
- int col = ((bgMax / 3) > bgCur) ? 1 : 0;
+ int col = ((bgMax / 3) > bgCur) ? guiSettings()->colors.guiColorYellow : guiSettings()->colors.guiColorDarkGreen;
if (bgCur <= 10)
- col = 2;
+ col = guiSettings()->colors.guiColorDarkRed;
if (!_currentControlMode)
- _screen->printText(_characterGuiStringsHp[0], x - 13, y - 1, guiSettings()->colors.menuTxtColBlack, 0);
+ _screen->printText(_characterGuiStringsHp[0], x - 13, y - 1, guiSettings()->colors.guiColorBlack, 0);
- gui_drawHorizontalBarGraph(x, y, w, h, bgCur, bgMax, barColor[col], guiSettings()->colors.barGraph);
+ gui_drawHorizontalBarGraph(x, y, w, h, bgCur, bgMax, col, guiSettings()->colors.barGraph);
} else {
Common::String tmpString = Common::String::format(_characterGuiStringsHp[1], c->hitPointsCur, c->hitPointsMax);
@@ -384,7 +384,7 @@ void EoBCoreEngine::gui_drawHitpoints(int index) {
y -= 1;
}
- _screen->printText(tmpString.c_str(), x, y, guiSettings()->colors.menuTxtColBlack, guiSettings()->colors.fill);
+ _screen->printText(tmpString.c_str(), x, y, guiSettings()->colors.guiColorBlack, bgCol);
}
}
@@ -402,11 +402,7 @@ void EoBCoreEngine::gui_drawFoodStatusGraph(int index) {
if (index != _updateCharNum)
return;
- static const uint8 barColorDefault[] = { 3, 5, 8 };
- static const uint8 barColorAmiga[] = { 27, 7, 25 };
- const uint8 *barColor = (_flags.platform == Common::kPlatformAmiga) ? barColorAmiga : barColorDefault;
-
- uint8 col = c->food < 20 ? barColor[2] : (c->food < 33 ? barColor[1] : barColor[0]);
+ uint8 col = c->food < 20 ? guiSettings()->colors.guiColorDarkRed : (c->food < 33 ? guiSettings()->colors.guiColorYellow : guiSettings()->colors.guiColorDarkGreen);
gui_drawHorizontalBarGraph(250, 25, 51, 5, c->food, 100, col, guiSettings()->colors.barGraph);
}
@@ -416,7 +412,7 @@ void EoBCoreEngine::gui_drawHorizontalBarGraph(int x, int y, int w, int h, int32
}
void EoBCoreEngine::gui_drawCharPortraitStatusFrame(int index) {
- uint8 redGreenColor = (_partyEffectFlags & 0x20000) ? 4 : ((_configRenderMode == Common::kRenderCGA) ? 3 : 6);
+ uint8 redGreenColor = (_partyEffectFlags & 0x20000) ? guiSettings()->colors.guiColorLightGreen : ((_configRenderMode == Common::kRenderCGA) ? 3 : guiSettings()->colors.guiColorLightRed);
static const uint8 xCoords[] = { 8, 80 };
static const uint8 yCoords[] = { 2, 54, 106 };
@@ -439,7 +435,7 @@ void EoBCoreEngine::gui_drawCharPortraitStatusFrame(int index) {
}
if (yellow && !redGreen) {
- _screen->drawBox(x, y, x + 63, y + 49, 5);
+ _screen->drawBox(x, y, x + 63, y + 49, guiSettings()->colors.guiColorYellow);
return;
}
@@ -453,8 +449,8 @@ void EoBCoreEngine::gui_drawCharPortraitStatusFrame(int index) {
_screen->drawClippedLine(x + 8, y + 49, x + 15, y + 49, redGreenColor);
}
if (yellow) {
- _screen->drawClippedLine(x + 8, y, x + 15, y, 5);
- _screen->drawClippedLine(x, y + 49, x + 7, y + 49, 5);
+ _screen->drawClippedLine(x + 8, y, x + 15, y, guiSettings()->colors.guiColorYellow);
+ _screen->drawClippedLine(x, y + 49, x + 7, y + 49, guiSettings()->colors.guiColorYellow);
}
}
@@ -464,8 +460,8 @@ void EoBCoreEngine::gui_drawCharPortraitStatusFrame(int index) {
y = iY + i - 1;
if (yellow) {
- _screen->drawClippedLine(x, y + 1, x, y + 6, 5);
- _screen->drawClippedLine(x + 63, y + 7, x + 63, y + 12, 5);
+ _screen->drawClippedLine(x, y + 1, x, y + 6, guiSettings()->colors.guiColorYellow);
+ _screen->drawClippedLine(x + 63, y + 7, x + 63, y + 12, guiSettings()->colors.guiColorYellow);
}
if (redGreen) {
_screen->drawClippedLine(x, y + 7, x, y + 12, redGreenColor);
@@ -476,8 +472,8 @@ void EoBCoreEngine::gui_drawCharPortraitStatusFrame(int index) {
} else {
_screen->drawClippedLine(x, y, x + 62, y, guiSettings()->colors.frame2);
_screen->drawClippedLine(x, y + 49, x + 62, y + 49, guiSettings()->colors.frame1);
- _screen->drawClippedLine(x - xOffset, y, x - xOffset, y + 50, 12);
- _screen->drawClippedLine(x + 63, y, x + 63, y + 50, 12);
+ _screen->drawClippedLine(x - xOffset, y, x - xOffset, y + 50, guiSettings()->colors.guiColorBlack);
+ _screen->drawClippedLine(x + 63, y, x + 63, y + 50, guiSettings()->colors.guiColorBlack);
}
}
@@ -504,11 +500,11 @@ void EoBCoreEngine::gui_drawInventoryItem(int slot, int redraw, int pageNum) {
gui_drawBox(x - 1, y - 1, wh, wh, col1, col2, slot == 16 ? -1 : guiSettings()->colors.fill);
if (slot == 16) {
- _screen->fillRect(227, 65, 238, 69, guiSettings()->colors.menuTxtColBlack);
+ _screen->fillRect(227, 65, 238, 69, guiSettings()->colors.guiColorBlack);
int cnt = countQueuedItems(_characters[_updateCharNum].inventory[slot], -1, -1, 1, 1);
x = cnt >= 10 ? 227 : 233;
Common::String str = Common::String::format("%d", cnt);
- _screen->printText(str.c_str(), x, 65, guiSettings()->colors.menuTxtColWhite, 0);
+ _screen->printText(str.c_str(), x, 65, guiSettings()->colors.guiColorWhite, 0);
}
}
@@ -574,12 +570,12 @@ void EoBCoreEngine::gui_drawSpellbook() {
if (_flags.gameID == GI_EOB1) {
gui_drawBox(i * 21 + 71, 122, 21, 9, col1, col2, col3);
- _screen->printText(_magicStrings7[i], i * 21 + 73, 123, guiSettings()->colors.menuTxtColBlack, 0);
+ _screen->printText(_magicStrings7[i], i * 21 + 73, 123, guiSettings()->colors.guiColorBlack, 0);
} else {
_screen->set16bitShadingLevel(4);
gui_drawBox(i * 18 + 68, 121, 18, 9, col1, col2, col3);
_screen->set16bitShadingLevel(0);
- _screen->printText(Common::String::format("%d", i + 1).c_str(), i * 18 + 75, 123, guiSettings()->colors.menuTxtColBlack, 0);
+ _screen->printText(Common::String::format("%d", i + 1).c_str(), i * 18 + 75, 123, guiSettings()->colors.guiColorBlack, 0);
}
}
@@ -596,8 +592,8 @@ void EoBCoreEngine::gui_drawSpellbook() {
gui_drawSpellbookScrollArrow(165, 169, 1);
}
- int textCol1 = (_configRenderMode == Common::kRenderCGA) ? 3 : guiSettings()->colors.menuTxtColWhite;
- int textCol2 = guiSettings()->colors.menuTxtColDarkRed;
+ int textCol1 = (_configRenderMode == Common::kRenderCGA) ? 3 : guiSettings()->colors.guiColorWhite;
+ int textCol2 = guiSettings()->colors.guiColorDarkRed;
int textXa = 74;
int textXs = 71;
int textY = 170;
@@ -1953,9 +1949,9 @@ void GUI_EoB::simpleMenu_setup(int sd, int maxItem, const char *const *strings,
for (int i = 0; i < _menuNumItems; i++) {
int item = simpleMenu_getMenuItem(i, menuItemsMask, itemOffset);
int ty = y + i * (lineSpacing + _screen->getFontHeight());
- _screen->printShadedText(strings[item], x, ty, (_vm->_configRenderMode == Common::kRenderCGA) ? 1 : _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(strings[item], x, ty, (_vm->_configRenderMode == Common::kRenderCGA) ? 1 : _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
if (item == v)
- _screen->printText(strings[item], x, ty, _vm->guiSettings()->colors.menuTxtColLightRed, 0);
+ _screen->printText(strings[item], x, ty, _vm->guiSettings()->colors.guiColorLightRed, 0);
}
_screen->updateScreen();
@@ -2006,14 +2002,14 @@ int GUI_EoB::simpleMenu_process(int sd, const char *const *strings, void *b, int
}
if (newItem != currentItem) {
- _screen->printText(strings[simpleMenu_getMenuItem(currentItem, menuItemsMask, itemOffset)], x, y + currentItem * lineH, (_vm->_configRenderMode == Common::kRenderCGA) ? 1 : _vm->guiSettings()->colors.menuTxtColWhite, 0);
- _screen->printText(strings[simpleMenu_getMenuItem(newItem, menuItemsMask, itemOffset)], x, y + newItem * lineH , _vm->guiSettings()->colors.menuTxtColLightRed, 0);
+ _screen->printText(strings[simpleMenu_getMenuItem(currentItem, menuItemsMask, itemOffset)], x, y + currentItem * lineH, (_vm->_configRenderMode == Common::kRenderCGA) ? 1 : _vm->guiSettings()->colors.guiColorWhite, 0);
+ _screen->printText(strings[simpleMenu_getMenuItem(newItem, menuItemsMask, itemOffset)], x, y + newItem * lineH , _vm->guiSettings()->colors.guiColorLightRed, 0);
_screen->updateScreen();
}
if (result != -1) {
result = simpleMenu_getMenuItem(result, menuItemsMask, itemOffset);
- simpleMenu_flashSelection(strings[result], x, y + newItem * lineH, _vm->guiSettings()->colors.menuTxtColWhite, _vm->guiSettings()->colors.menuTxtColLightRed, 0);
+ simpleMenu_flashSelection(strings[result], x, y + newItem * lineH, _vm->guiSettings()->colors.guiColorWhite, _vm->guiSettings()->colors.guiColorLightRed, 0);
}
_menuCur = newItem;
@@ -2292,7 +2288,7 @@ void GUI_EoB::runCampMenu() {
_vm->writeSettings();
}
-bool GUI_EoB::runLoadMenu(int x, int y) {
+bool GUI_EoB::runLoadMenu(int x, int y, bool fromMainMenu) {
const ScreenDim *dm = _screen->getScreenDim(11);
int xo = dm->sx;
int yo = dm->sy;
@@ -2302,15 +2298,24 @@ bool GUI_EoB::runLoadMenu(int x, int y) {
for (bool runLoop = true; runLoop && !_vm->shouldQuit();) {
updateSaveSlotsList(_vm->_targetName);
+
+ _vm->useMainMenuGUISettings(fromMainMenu);
int slot = selectSaveSlotDialogue(x, y, 1);
+ _vm->useMainMenuGUISettings(false);
+
if (slot > 5) {
runLoop = result = false;
} else if (slot >= 0) {
if (_saveSlotIdTemp[slot] == -1) {
- messageDialogue(11, 65, _vm->guiSettings()->colors.menuTxtColLightRed);
+ _vm->useMainMenuGUISettings(fromMainMenu);
+ messageDialogue(11, 65, _vm->guiSettings()->colors.guiColorLightRed);
+ _vm->useMainMenuGUISettings(false);
} else {
- if (_vm->loadGameState(_saveSlotIdTemp[slot]).getCode() != Common::kNoError)
- messageDialogue(11, 16, _vm->guiSettings()->colors.menuTxtColLightRed);
+ if (_vm->loadGameState(_saveSlotIdTemp[slot]).getCode() != Common::kNoError) {
+ _vm->useMainMenuGUISettings(fromMainMenu);
+ messageDialogue(11, 16, _vm->guiSettings()->colors.guiColorLightRed);
+ _vm->useMainMenuGUISettings(false);
+ }
runLoop = false;
result = true;
}
@@ -2318,6 +2323,7 @@ bool GUI_EoB::runLoadMenu(int x, int y) {
}
_screen->modifyScreenDim(11, xo, yo, dm->w, dm->h);
+
return result;
}
@@ -2370,7 +2376,7 @@ bool GUI_EoB::confirmDialogue2(int dim, int id, int deflt) {
if (newHighlight != lastHighlight) {
for (int i = 0; i < 2; i++)
- _screen->printShadedText(_vm->_menuYesNoStrings[i], x[i] + 16 - (_screen->getTextWidth(_vm->_menuYesNoStrings[i]) / 2) + 1, y + 3, i == newHighlight ? _vm->guiSettings()->colors.menuTxtColLightRed : _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_vm->_menuYesNoStrings[i], x[i] + 16 - (_screen->getTextWidth(_vm->_menuYesNoStrings[i]) / 2) + 1, y + 3, i == newHighlight ? _vm->guiSettings()->colors.guiColorLightRed : _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->updateScreen();
lastHighlight = newHighlight;
}
@@ -2402,7 +2408,7 @@ void GUI_EoB::messageDialogue(int dim, int id, int buttonTextCol) {
int bw = _screen->getTextWidth(_vm->_menuOkString) + 7;
drawMenuButtonBox(bx, by, bw, 14, false, false);
- _screen->printShadedText(_vm->_menuOkString, bx + 4, by + 3, buttonTextCol, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_vm->_menuOkString, bx + 4, by + 3, buttonTextCol, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->updateScreen();
for (bool runLoop = true; runLoop && !_vm->shouldQuit();) {
@@ -2433,7 +2439,7 @@ void GUI_EoB::messageDialogue2(int dim, int id, int buttonTextCol) {
_screen->_curPage = 2;
_screen->setClearScreenDim(dim);
drawMenuButtonBox(_screen->_curDim->sx << 3, _screen->_curDim->sy, _screen->_curDim->w << 3, _screen->_curDim->h, false, false);
- _screen->printShadedText(getMenuString(id), (_screen->_curDim->sx << 3) + 5, _screen->_curDim->sy + 5, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(getMenuString(id), (_screen->_curDim->sx << 3) + 5, _screen->_curDim->sy + 5, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->_curPage = 0;
_screen->copyRegion(_screen->_curDim->sx << 3, _screen->_curDim->sy, _screen->_curDim->sx << 3, _screen->_curDim->sy, _screen->_curDim->w << 3, _screen->_curDim->h, 2, 0, Screen::CR_NO_P_CHECK);
@@ -2441,7 +2447,7 @@ void GUI_EoB::messageDialogue2(int dim, int id, int buttonTextCol) {
int y = _screen->_curDim->sy + _screen->_curDim->h - 21;
int w = _screen->getTextWidth(_vm->_menuOkString) + 8;
drawMenuButtonBox(x, y, w, 14, false, false);
- _screen->printShadedText(_vm->_menuOkString, x + 4, y + 3, buttonTextCol, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_vm->_menuOkString, x + 4, y + 3, buttonTextCol, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->updateScreen();
for (bool runLoop = true; runLoop && !_vm->shouldQuit();) {
@@ -2462,7 +2468,7 @@ void GUI_EoB::messageDialogue2(int dim, int id, int buttonTextCol) {
_screen->updateScreen();
_vm->_system->delayMillis(80);
drawMenuButtonBox(x, y, w, 14, false, false);
- _screen->printShadedText(_vm->_menuOkString, x + 4, y + 3, buttonTextCol, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_vm->_menuOkString, x + 4, y + 3, buttonTextCol, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->updateScreen();
}
@@ -2519,7 +2525,7 @@ int GUI_EoB::getTextInput(char *dest, int x, int y, int destMaxLen, int textColo
_screen->copyRegion((x - 1) << 3, y, 0, 191, (destMaxLen + 2) << 3, 9, 0, 2, Screen::CR_NO_P_CHECK);
if (_vm->gameFlags().platform == Common::kPlatformFMTowns)
_screen->copyRegion(0, 0, 160, 0, 160, 128, 2, 2, Screen::CR_NO_P_CHECK);
- _screen->printShadedText(dest, x << 3, y, textColor1, textColor2, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(dest, x << 3, y, textColor1, textColor2, _vm->guiSettings()->colors.guiColorBlack);
uint32 next = _vm->_system->getMillis() + 2 * _vm->_tickLength;
sufx[0] = (pos < len) ? dest[pos] : 32;
@@ -2538,7 +2544,7 @@ int GUI_EoB::getTextInput(char *dest, int x, int y, int destMaxLen, int textColo
if (next <= _vm->_system->getMillis()) {
if (cursorState) {
_screen->copyRegion((pos + 1) << 3, 191, (x + pos) << 3, y, 8, 9, 2, 0, Screen::CR_NO_P_CHECK);
- _screen->printShadedText(sufx, (x + pos) << 3, y, textColor1, textColor2, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(sufx, (x + pos) << 3, y, textColor1, textColor2, _vm->guiSettings()->colors.guiColorBlack);
} else {
_screen->fillRect((x + pos) << 3, y, ((x + pos) << 3) + 7, y + 7, cursorColor);
_screen->printText(sufx, (x + pos) << 3, y, textColor1, cursorColor);
@@ -2653,7 +2659,7 @@ int GUI_EoB::getTextInput(char *dest, int x, int y, int destMaxLen, int textColo
}
_screen->copyRegion(0, 191, (x - 1) << 3, y, (destMaxLen + 2) << 3, 9, 2, 0, Screen::CR_NO_P_CHECK);
- _screen->printShadedText(dest, x << 3, y, textColor1, textColor2, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(dest, x << 3, y, textColor1, textColor2, _vm->guiSettings()->colors.guiColorBlack);
if (_vm->_flags.platform == Common::kPlatformFMTowns) {
if (pos < len) {
@@ -2670,7 +2676,7 @@ int GUI_EoB::getTextInput(char *dest, int x, int y, int destMaxLen, int textColo
if (cursorState)
_screen->printText(sufx, (x + pos) << 3, y, textColor1, cursorColor);
else
- _screen->printShadedText(sufx, (x + pos) << 3, y, textColor1, textColor2, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(sufx, (x + pos) << 3, y, textColor1, textColor2, _vm->guiSettings()->colors.guiColorBlack);
_screen->updateScreen();
} while (_keyPressed.keycode != Common::KEYCODE_RETURN && _keyPressed.keycode != Common::KEYCODE_ESCAPE && !_vm->shouldQuit());
@@ -2704,7 +2710,7 @@ int GUI_EoB::checkKatakanaSelection() {
if (_csjis[0] != '\x81' || _csjis[1] != '\x40') {
highlight = lineOffs << 8 | column;
- _screen->printShadedText(_csjis, x & ~7, y & ~15, _vm->guiSettings()->colors.menuTxtColLightRed, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_csjis, x & ~7, y & ~15, _vm->guiSettings()->colors.guiColorLightRed, 0, _vm->guiSettings()->colors.guiColorBlack);
}
x = 288; y = 168;
@@ -2717,7 +2723,7 @@ int GUI_EoB::checkKatakanaSelection() {
continue;
highlight = 0x400 | i;
- _screen->printShadedText(_vm->_katakanaSelectStrings[i], kanaSelXCrds[i], 176, _vm->guiSettings()->colors.menuTxtColLightRed, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_vm->_katakanaSelectStrings[i], kanaSelXCrds[i], 176, _vm->guiSettings()->colors.guiColorLightRed, 0, _vm->guiSettings()->colors.guiColorBlack);
i = 3;
}
}
@@ -2733,13 +2739,13 @@ int GUI_EoB::checkKatakanaSelection() {
if (_menuCur != -1) {
if (_menuCur & 0x400) {
- _screen->printShadedText(_vm->_katakanaSelectStrings[_menuCur & 3], kanaSelXCrds[_menuCur & 3], 176, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_vm->_katakanaSelectStrings[_menuCur & 3], kanaSelXCrds[_menuCur & 3], 176, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
} else {
char osjis[3];
osjis[0] = _vm->_katakanaLines[_currentKanaPage * 4 + (_menuCur >> 8)][_menuCur & 0xFF];
osjis[1] = _vm->_katakanaLines[_currentKanaPage * 4 + (_menuCur >> 8)][(_menuCur & 0xFF) + 1];
osjis[2] = 0;
- _screen->printShadedText(osjis, 152 + ((_menuCur & 0xFF) << 2), 112 + ((_menuCur >> 4) & ~0x0F), _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(osjis, 152 + ((_menuCur & 0xFF) << 2), 112 + ((_menuCur >> 4) & ~0x0F), _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
}
}
@@ -2777,11 +2783,11 @@ void GUI_EoB::printKatakanaOptions(int page) {
_currentKanaPage = page;
_screen->copyRegion(160, 44, 144, 108, 160, 84, 2, 0, Screen::CR_NO_P_CHECK);
for (int i = 0; i < 4; i++)
- _screen->printShadedText(_vm->_katakanaLines[page * 4 + i], 152, (i << 4) + 112, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_vm->_katakanaLines[page * 4 + i], 152, (i << 4) + 112, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
static uint16 kanaSelCrds[] = { 224, 272, 186 };
for (int i = 0; i < 3; i++)
- _screen->printShadedText(_vm->_katakanaSelectStrings[i], kanaSelCrds[i], 176, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_vm->_katakanaSelectStrings[i], kanaSelCrds[i], 176, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
}
void GUI_EoB::transferWaitBox() {
@@ -2848,7 +2854,7 @@ bool GUI_EoB::transferFileMenu(Common::String &targetName, Common::String &selec
break;
if (_saveSlotIdTemp[slot] == -1)
- messageDialogue(11, 65, _vm->guiSettings()->colors.menuTxtColLightRed);
+ messageDialogue(11, 65, _vm->guiSettings()->colors.guiColorLightRed);
else {
_screen->modifyScreenDim(11, xo, yo, dm->w, dm->h);
selection = _vm->getSavegameFilename(targetName, _saveSlotIdTemp[slot]);
@@ -2919,7 +2925,7 @@ bool GUI_EoB::runSaveMenu(int x, int y) {
of = _vm->screen()->setFont(Screen::FID_6_FNT);
y++;
} else {
- in = getTextInput(_saveSlotStringsTemp[slot], x + 1, fy, 19, _vm->guiSettings()->colors.menuTxtColBlue, 0, _vm->guiSettings()->colors.menuTxtColDarkRed);
+ in = getTextInput(_saveSlotStringsTemp[slot], x + 1, fy, 19, _vm->guiSettings()->colors.guiColorBlue, 0, _vm->guiSettings()->colors.guiColorDarkRed);
}
if (in == -1) {
useSlot = false;
@@ -2927,7 +2933,7 @@ bool GUI_EoB::runSaveMenu(int x, int y) {
}
if (!strlen(_saveSlotStringsTemp[slot])) {
- messageDialogue(11, 54, _vm->guiSettings()->colors.menuTxtColLightRed);
+ messageDialogue(11, 54, _vm->guiSettings()->colors.guiColorLightRed);
in = -1;
}
}
@@ -2937,7 +2943,7 @@ bool GUI_EoB::runSaveMenu(int x, int y) {
}
_screen->fillRect(fx - 2, fy, fx + 160, fy + 8, _vm->guiSettings()->colors.fill);
- _screen->printShadedText(_saveSlotStringsTemp[slot], (x + 1) << 3, fy, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_saveSlotStringsTemp[slot], (x + 1) << 3, fy, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->set16bitShadingLevel(0);
_screen->setFont(of);
_screen->updateScreen();
@@ -2950,7 +2956,7 @@ bool GUI_EoB::runSaveMenu(int x, int y) {
if (err.getCode() == Common::kNoError)
result = true;
else
- messageDialogue(11, 15, _vm->guiSettings()->colors.menuTxtColLightRed);
+ messageDialogue(11, 15, _vm->guiSettings()->colors.guiColorLightRed);
runLoop = false;
}
@@ -2962,14 +2968,14 @@ bool GUI_EoB::runSaveMenu(int x, int y) {
int GUI_EoB::selectSaveSlotDialogue(int x, int y, int id) {
_saveSlotX = _saveSlotY = 0;
- int col1 = (_vm->_configRenderMode == Common::kRenderCGA) ? 1 : _vm->guiSettings()->colors.menuTxtColWhite;
+ int col1 = (_vm->_configRenderMode == Common::kRenderCGA) ? 1 : _vm->guiSettings()->colors.guiColorWhite;
_screen->setCurPage(2);
_savegameOffset = 0;
drawMenuButtonBox(0, 0, 176, 144, false, false);
const char *title = (id < 2) ? _vm->_saveLoadStrings[2 + id] : _vm->_transferStringsScummVM[id - 1];
- _screen->printShadedText(title, 52, 5, col1, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(title, 52, 5, col1, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->copyRegion(0, 0, x, y, 176, 144, 2, 0, Screen::CR_NO_P_CHECK);
_screen->setCurPage(0);
@@ -3048,7 +3054,7 @@ int GUI_EoB::selectSaveSlotDialogue(int x, int y, int id) {
if (lastHighlight != newHighlight) {
drawSaveSlotButton(lastHighlight, 0, col1);
- drawSaveSlotButton(newHighlight, 0, _vm->guiSettings()->colors.menuTxtColLightRed);
+ drawSaveSlotButton(newHighlight, 0, _vm->guiSettings()->colors.guiColorLightRed);
// Display highlighted slot index in the bottom left corner to avoid people getting lost with the 990 save slots
_screen->setFont(Screen::FID_6_FNT);
@@ -3063,10 +3069,10 @@ int GUI_EoB::selectSaveSlotDialogue(int x, int y, int id) {
}
}
- drawSaveSlotButton(newHighlight, 2, _vm->guiSettings()->colors.menuTxtColLightRed);
+ drawSaveSlotButton(newHighlight, 2, _vm->guiSettings()->colors.guiColorLightRed);
_screen->updateScreen();
_vm->_system->delayMillis(80);
- drawSaveSlotButton(newHighlight, 1, _vm->guiSettings()->colors.menuTxtColLightRed);
+ drawSaveSlotButton(newHighlight, 1, _vm->guiSettings()->colors.guiColorLightRed);
_screen->updateScreen();
return newHighlight;
@@ -3215,7 +3221,7 @@ void GUI_EoB::runMemorizePrayMenu(int charIndex, int spellType) {
if (updateDesc) {
updateDesc = false;
_screen->set16bitShadingLevel(4);
- _screen->printShadedText(Common::String::format(_vm->_menuStringsMgc[1], np[lastHighLightButton] - numAssignedSpellsPerBookPage[lastHighLightButton], np[lastHighLightButton]).c_str(), 8, 38, 9, _vm->guiSettings()->colors.fill, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(Common::String::format(_vm->_menuStringsMgc[1], np[lastHighLightButton] - numAssignedSpellsPerBookPage[lastHighLightButton], np[lastHighLightButton]).c_str(), 8, 38, 9, _vm->guiSettings()->colors.fill, _vm->guiSettings()->colors.guiColorBlack);
_screen->set16bitShadingLevel(0);
}
@@ -3408,7 +3414,7 @@ void GUI_EoB::scribeScrollDialogue() {
buttonList = initMenu(6);
for (int i = 0; i < s; i++)
- _screen->printShadedText(_vm->_mageSpellList[menuItems[i]], 8, 9 * i + 50, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(_vm->_mageSpellList[menuItems[i]], 8, 9 * i + 50, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
redraw = false;
lastHighLight = -1;
@@ -3417,9 +3423,9 @@ void GUI_EoB::scribeScrollDialogue() {
if (lastHighLight != newHighLight) {
if (lastHighLight >= 0)
- _screen->printText(_vm->_mageSpellList[menuItems[lastHighLight]], 8, 9 * lastHighLight + 50, _vm->guiSettings()->colors.menuTxtColWhite, 0);
+ _screen->printText(_vm->_mageSpellList[menuItems[lastHighLight]], 8, 9 * lastHighLight + 50, _vm->guiSettings()->colors.guiColorWhite, 0);
lastHighLight = newHighLight;
- _screen->printText(_vm->_mageSpellList[menuItems[lastHighLight]], 8, 9 * lastHighLight + 50, _vm->guiSettings()->colors.menuTxtColLightRed, 0);
+ _screen->printText(_vm->_mageSpellList[menuItems[lastHighLight]], 8, 9 * lastHighLight + 50, _vm->guiSettings()->colors.guiColorLightRed, 0);
_screen->updateScreen();
}
@@ -3761,7 +3767,7 @@ bool GUI_EoB::confirmDialogue(int id) {
Button *buttonList = initMenu(5);
- _screen->printShadedText(getMenuString(id), (_screen->_curDim->sx + 1) << 3, _screen->_curDim->sy + 4, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(getMenuString(id), (_screen->_curDim->sx + 1) << 3, _screen->_curDim->sy + 4, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
int newHighlight = 0;
int lastHighlight = -1;
@@ -3983,7 +3989,7 @@ void GUI_EoB::displayTextBox(int id) {
const ScreenDim *dm = _screen->getScreenDim(11);
drawMenuButtonBox(dm->sx << 3, dm->sy, dm->w << 3, dm->h, false, false);
- _screen->printShadedText(getMenuString(id), (dm->sx << 3) + 5, dm->sy + 5, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(getMenuString(id), (dm->sx << 3) + 5, dm->sy + 5, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->copyRegion(dm->sx << 3, dm->sy, dm->sx << 3, dm->sy, dm->w << 3, dm->h, 2, 0, Screen::CR_NO_P_CHECK);
_screen->updateScreen();
@@ -4012,7 +4018,7 @@ Button *GUI_EoB::initMenu(int id) {
drawMenuButtonBox(dm->sx << 3, dm->sy, dm->w << 3, dm->h, false, false);
}
- _screen->printShadedText(getMenuString(m->titleStrId), 5, 5, m->titleCol, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(getMenuString(m->titleStrId), 5, 5, m->titleCol, 0, _vm->guiSettings()->colors.guiColorBlack);
Button *buttons = 0;
for (int i = 0; i < m->numButtons; i++) {
@@ -4069,12 +4075,12 @@ void GUI_EoB::drawMenuButton(Button *b, bool clicked, bool highlight, bool noFil
yOffs = (b->height - 7) >> 1;
}
- int col1 = (_vm->_configRenderMode == Common::kRenderCGA) ? 1 : _vm->guiSettings()->colors.menuTxtColWhite;
+ int col1 = (_vm->_configRenderMode == Common::kRenderCGA) ? 1 : _vm->guiSettings()->colors.guiColorWhite;
if (noFill || clicked)
- _screen->printText(s, b->x + xOffs, b->y + yOffs, highlight ? _vm->guiSettings()->colors.menuTxtColLightRed : col1, 0);
+ _screen->printText(s, b->x + xOffs, b->y + yOffs, highlight ? _vm->guiSettings()->colors.guiColorLightRed : col1, 0);
else
- _screen->printShadedText(s, b->x + xOffs, b->y + yOffs, highlight ? _vm->guiSettings()->colors.menuTxtColLightRed : col1, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(s, b->x + xOffs, b->y + yOffs, highlight ? _vm->guiSettings()->colors.guiColorLightRed : col1, 0, _vm->guiSettings()->colors.guiColorBlack);
}
}
@@ -4103,7 +4109,7 @@ void GUI_EoB::drawTextBox(int dim, int id) {
_screen->setCurPage(2);
drawMenuButtonBox(0, 0, dm->w << 3, dm->h, false, false);
- _screen->printShadedText(getMenuString(id), 5, 5, _vm->guiSettings()->colors.menuTxtColWhite, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(getMenuString(id), 5, 5, _vm->guiSettings()->colors.guiColorWhite, 0, _vm->guiSettings()->colors.guiColorBlack);
_screen->setCurPage(0);
_screen->copyRegion(0, 0, dm->sx << 3, dm->sy, dm->w << 3, dm->h, 2, 0, Screen::CR_NO_P_CHECK);
@@ -4137,7 +4143,7 @@ void GUI_EoB::drawSaveSlotButton(int slot, int redrawBox, int textCol) {
y++;
}
- _screen->printShadedText(slotString, x + 4, y + 3, textCol, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(slotString, x + 4, y + 3, textCol, 0, _vm->guiSettings()->colors.guiColorBlack);
_vm->screen()->setFont(fnt);
}
@@ -4146,7 +4152,7 @@ void GUI_EoB::memorizePrayMenuPrintString(int spellId, int bookPageIndex, int sp
return;
int y = bookPageIndex * 9 + 50;
- int col1 = (_vm->_configRenderMode == Common::kRenderCGA) ? 1 : _vm->guiSettings()->colors.menuTxtColWhite;
+ int col1 = (_vm->_configRenderMode == Common::kRenderCGA) ? 1 : _vm->guiSettings()->colors.guiColorWhite;
_screen->set16bitShadingLevel(4);
if (spellId) {
@@ -4161,9 +4167,9 @@ void GUI_EoB::memorizePrayMenuPrintString(int spellId, int bookPageIndex, int sp
}
if (noFill)
- _screen->printText(s.c_str(), 8, y, highLight ? _vm->guiSettings()->colors.menuTxtColLightRed : col1, 0);
+ _screen->printText(s.c_str(), 8, y, highLight ? _vm->guiSettings()->colors.guiColorLightRed : col1, 0);
else
- _screen->printShadedText(s.c_str(), 8, y, highLight ? _vm->guiSettings()->colors.menuTxtColLightRed : col1, _vm->guiSettings()->colors.fill, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(s.c_str(), 8, y, highLight ? _vm->guiSettings()->colors.guiColorLightRed : col1, _vm->guiSettings()->colors.fill, _vm->guiSettings()->colors.guiColorBlack);
} else {
_screen->fillRect(6, y, 168, y + 8, _vm->guiSettings()->colors.fill);
}
@@ -4308,13 +4314,13 @@ void GUI_EoB::restParty_updateRestTime(int hours, bool init) {
_vm->_txt->clearCurDim();
drawMenuButtonBox(_screen->_curDim->sx << 3, _screen->_curDim->sy, _screen->_curDim->w << 3, _screen->_curDim->h, false, false);
_screen->copyRegion(_screen->_curDim->sx << 3, _screen->_curDim->sy, _screen->_curDim->sx << 3, _screen->_curDim->sy, _screen->_curDim->w << 3, _screen->_curDim->h, 0, 2, Screen::CR_NO_P_CHECK);
- _screen->printShadedText(getMenuString(42), (_screen->_curDim->sx + 1) << 3, _screen->_curDim->sy + 5, 9, 0, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(getMenuString(42), (_screen->_curDim->sx + 1) << 3, _screen->_curDim->sy + 5, 9, 0, _vm->guiSettings()->colors.guiColorBlack);
}
_screen->setCurPage(0);
_screen->set16bitShadingLevel(4);
_screen->fillRect((_screen->_curDim->sx + 1) << 3, _screen->_curDim->sy + 20, ((_screen->_curDim->sx + 19) << 3) + 1, _screen->_curDim->sy + 29, _vm->guiSettings()->colors.fill);
- _screen->printShadedText(Common::String::format(_vm->_menuStringsRest2[3], hours).c_str(), (_screen->_curDim->sx + 1) << 3, _screen->_curDim->sy + 20, _vm->guiSettings()->colors.menuTxtColWhite, _vm->guiSettings()->colors.fill, _vm->guiSettings()->colors.menuTxtColBlack);
+ _screen->printShadedText(Common::String::format(_vm->_menuStringsRest2[3], hours).c_str(), (_screen->_curDim->sx + 1) << 3, _screen->_curDim->sy + 20, _vm->guiSettings()->colors.guiColorWhite, _vm->guiSettings()->colors.fill, _vm->guiSettings()->colors.guiColorBlack);
_screen->set16bitShadingLevel(0);
_screen->updateScreen();
_vm->delay(160);
diff --git a/engines/kyra/gui/gui_eob.h b/engines/kyra/gui/gui_eob.h
index 82721fca95..0e10d56b6e 100644
--- a/engines/kyra/gui/gui_eob.h
+++ b/engines/kyra/gui/gui_eob.h
@@ -60,7 +60,7 @@ public:
// Button based menus (camp menu, load menu)
void runCampMenu();
- bool runLoadMenu(int x, int y);
+ bool runLoadMenu(int x, int y, bool fromMainMenu = false);
bool confirmDialogue2(int dim, int id, int deflt);
void messageDialogue(int dim, int id, int buttonTextCol);
diff --git a/engines/kyra/resource/staticres_eob.cpp b/engines/kyra/resource/staticres_eob.cpp
index ed2f36895e..281cb7f6db 100644
--- a/engines/kyra/resource/staticres_eob.cpp
+++ b/engines/kyra/resource/staticres_eob.cpp
@@ -804,8 +804,8 @@ void EoBCoreEngine::initMenus() {
if (_flags.platform == Common::kPlatformAmiga) {
// assign Amiga text colors
- _menuDefs[0].titleCol = _menuDefs[1].titleCol = _menuDefs[2].titleCol = _menuDefs[4].titleCol = _menuDefs[6].titleCol = guiSettings()->colors.menuTxtColLightBlue;
- _menuDefs[3].titleCol = _menuDefs[5].titleCol = guiSettings()->colors.menuTxtColWhite;
+ _menuDefs[0].titleCol = _menuDefs[1].titleCol = _menuDefs[2].titleCol = _menuDefs[4].titleCol = _menuDefs[6].titleCol = guiSettings()->colors.guiColorLightBlue;
+ _menuDefs[3].titleCol = _menuDefs[5].titleCol = guiSettings()->colors.guiColorWhite;
}
}
@@ -1290,17 +1290,22 @@ void EoBEngine::initSpells() {
const KyraRpgGUISettings EoBEngine::_guiSettingsVGA = {
{ 9, 15, 95, 9, 7, { 285, 139 }, { 189, 162 }, { 31, 31 } },
- { 135, 130, 132, 180, 133, 17, 23, 20, 184, 177, 180, 184, 177, 180, 15, 6, 8, 9, 2, 12 }
+ { 135, 130, 132, 180, 133, 17, 23, 20, 184, 177, 180, 184, 177, 180, 15, 6, 8, 9, 2, 5, 4, 3, 12 }
};
const KyraRpgGUISettings EoBEngine::_guiSettingsEGA = {
{ 9, 15, 95, 9, 7, { 285, 139 }, { 189, 162 }, { 31, 31 } },
- { 13, 9, 2, 14, 2, 6, 13, 8, 13, 15, 14, 13, 15, 14, 15, 6, 8, 9, 2, 12 }
+ { 13, 9, 2, 14, 2, 6, 13, 8, 13, 15, 14, 13, 15, 14, 15, 6, 8, 9, 2, 5, 4, 3, 12 }
};
const KyraRpgGUISettings EoBEngine::_guiSettingsAmiga = {
{ 28, 31, 95, 9, 7, { 285, 139 }, { 189, 162 }, { 31, 31 } },
- { 18, 17, 10, 17, 11, 24, 22, 25, 18, 9, 10, 18, 9, 10, 31, 24, 25, 28, 29, 19 }
+ { 18, 17, 10, 17, 11, 24, 22, 25, 18, 9, 10, 18, 9, 10, 31, 24, 25, 28, 29, 7, 26, 27, 19 }
+};
+
+const KyraRpgGUISettings EoBEngine::_guiSettingsAmigaMainMenu = {
+ { 28, 31, 95, 9, 7, { 285, 139 }, { 189, 162 }, { 31, 31 } },
+ { 22, 28, 30, 17, 11, 24, 22, 25, 18, 9, 10, 18, 9, 10, 31, 24, 25, 28, 29, 7, 26, 27, 19 }
};
const uint8 EoBEngine::_egaDefaultPalette[] = {
@@ -1401,12 +1406,12 @@ void DarkMoonEngine::initSpells() {
const KyraRpgGUISettings DarkMoonEngine::_guiSettingsFMTowns = {
{ 9, 15, 95, 11, 7, { 221, 76 }, { 187, 162 }, { 95, 95 } },
- { 186, 181, 183, 183, 184, 17, 23, 20, 186, 181, 183, 182, 177, 180, 15, 6, 8, 9, 2, 12 }
+ { 186, 181, 183, 183, 184, 17, 23, 20, 186, 181, 183, 182, 177, 180, 15, 6, 8, 9, 2, 5, 4, 3, 12 }
};
const KyraRpgGUISettings DarkMoonEngine::_guiSettingsDOS = {
{ 9, 15, 95, 9, 7, { 221, 76 }, { 189, 162 }, { 95, 95 } },
- { 186, 181, 183, 183, 184, 17, 23, 20, 186, 181, 183, 182, 177, 180, 15, 6, 8, 9, 2, 12 }
+ { 186, 181, 183, 183, 184, 17, 23, 20, 186, 181, 183, 182, 177, 180, 15, 6, 8, 9, 2, 5, 4, 3, 12 }
};
const uint8 DarkMoonEngine::_egaDefaultPalette[] = {
diff --git a/engines/kyra/resource/staticres_lol.cpp b/engines/kyra/resource/staticres_lol.cpp
index d2fbcef16f..24076aaef7 100644
--- a/engines/kyra/resource/staticres_lol.cpp
+++ b/engines/kyra/resource/staticres_lol.cpp
@@ -779,7 +779,7 @@ const int8 LoLEngine::_mapCoords[12][4] = {
const KyraRpgGUISettings LoLEngine::_guiSettings = {
{ 144, 254, 74, 9, 80, { 0, 0 }, { 0, 0 }, { 0, 0 } },
- { 136, 251, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }
+ { 136, 251, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }
};
const MistOfDoomAnimData LoLEngine::_mistAnimData[] = {
diff --git a/engines/kyra/text/text_rpg.cpp b/engines/kyra/text/text_rpg.cpp
index d865fc754c..6f1ed2a9e7 100644
--- a/engines/kyra/text/text_rpg.cpp
+++ b/engines/kyra/text/text_rpg.cpp
@@ -49,12 +49,12 @@ TextDisplayer_rpg::TextDisplayer_rpg(KyraRpgEngine *engine, Screen *scr) : _vm(e
_colorMap[i] = i;
if (_vm->game() != GI_LOL) {
- _colorMap[15] = _vm->guiSettings()->colors.menuTxtColWhite;
- _colorMap[6] = _vm->guiSettings()->colors.menuTxtColLightRed;
- _colorMap[8] = _vm->guiSettings()->colors.menuTxtColDarkRed;
- _colorMap[9] = _vm->guiSettings()->colors.menuTxtColLightBlue;
- _colorMap[2] = _vm->guiSettings()->colors.menuTxtColBlue;
- _colorMap[12] = _vm->guiSettings()->colors.menuTxtColBlack;
+ _colorMap[15] = _vm->guiSettings()->colors.guiColorWhite;
+ _colorMap[6] = _vm->guiSettings()->colors.guiColorLightRed;
+ _colorMap[8] = _vm->guiSettings()->colors.guiColorDarkRed;
+ _colorMap[9] = _vm->guiSettings()->colors.guiColorLightBlue;
+ _colorMap[2] = _vm->guiSettings()->colors.guiColorBlue;
+ _colorMap[12] = _vm->guiSettings()->colors.guiColorBlack;
}
for (int i = 0; i < _screen->screenDimTableCount(); i++) {