aboutsummaryrefslogtreecommitdiff
path: root/engines/kyra/script
diff options
context:
space:
mode:
authorathrxx2019-01-30 00:24:31 +0100
committerathrxx2019-03-06 20:48:21 +0100
commit7b8c84fa4d3f3d8e1c5fa543fae7ddbd7a495bb7 (patch)
treea4dd3631826170611174434f37d16d3fb5d0ea32 /engines/kyra/script
parente00eaa4899d86fb97c333d4b609de4612895ffea (diff)
downloadscummvm-rg350-7b8c84fa4d3f3d8e1c5fa543fae7ddbd7a495bb7.tar.gz
scummvm-rg350-7b8c84fa4d3f3d8e1c5fa543fae7ddbd7a495bb7.tar.bz2
scummvm-rg350-7b8c84fa4d3f3d8e1c5fa543fae7ddbd7a495bb7.zip
KYRA: (EOB1/Amiga) - fix chargen and gui colors
Diffstat (limited to 'engines/kyra/script')
-rw-r--r--engines/kyra/script/script_eob.cpp15
1 files changed, 12 insertions, 3 deletions
diff --git a/engines/kyra/script/script_eob.cpp b/engines/kyra/script/script_eob.cpp
index 709921deb9..cc3fc0a84f 100644
--- a/engines/kyra/script/script_eob.cpp
+++ b/engines/kyra/script/script_eob.cpp
@@ -514,6 +514,7 @@ int EoBInfProcessor::oeob_moveInventoryItemToBlock(int8 *data) {
}
int EoBInfProcessor::oeob_printMessage_v1(int8 *data) {
+ static const uint8 amigaColorMap[16] = { 0x00, 0x06, 0x1d, 0x1b, 0x1a, 0x17, 0x18, 0x0e, 0x19, 0x1c, 0x1c, 0x1e, 0x13, 0x0a, 0x11, 0x1f };
static const char colorConfig[] = "\x6\x21\x2\x21";
char col[5];
int8 *pos = data;
@@ -524,11 +525,19 @@ int EoBInfProcessor::oeob_printMessage_v1(int8 *data) {
col[1] = *pos++;
col[3] = *pos++;
+
+ if (_vm->gameFlags().platform == Common::kPlatformAmiga) {
+ assert(col[1] < 16);
+ assert(col[3] < 16);
+ col[1] = amigaColorMap[col[1]];
+ col[3] = amigaColorMap[col[3]];
+ }
+
_vm->txt()->printMessage(col);
_vm->txt()->printMessage(str);
- col[1] = _screen->_curDim->unk8;
- col[3] = _screen->_curDim->unkA;
+ col[1] = _vm->txt()->colorMap()[_screen->_curDim->unk8];
+ col[3] = _vm->txt()->colorMap()[_screen->_curDim->unkA];
_vm->txt()->printMessage(col);
_vm->txt()->printMessage("\r");
@@ -1495,7 +1504,7 @@ int EoBInfProcessor::oeob_sequence(int8 *data) {
break;
case -1:
- if (_vm->gameFlags().platform == Common::kPlatformDOS)
+ if (_vm->gameFlags().platform == Common::kPlatformDOS || _vm->gameFlags().platform == Common::kPlatformAmiga)
_vm->_runFlag = _vm->checkPassword();
break;