mirror of
https://github.com/libretro/scummvm.git
synced 2025-02-04 09:56:30 +00:00
Add string height override for loom
svn-id: r17178
This commit is contained in:
parent
749cf8a083
commit
47e9cc1b3a
@ -2641,9 +2641,10 @@ void ScummEngine_v5::decodeParseString() {
|
||||
break;
|
||||
case 3: // SO_ERASE
|
||||
{
|
||||
int a = getVarOrDirectWord(PARAM_1);
|
||||
int b = getVarOrDirectWord(PARAM_2);
|
||||
warning("ScummEngine_v5::decodeParseString: Unhandled case 3: %d, %d", a, b);
|
||||
int w = getVarOrDirectWord(PARAM_1);
|
||||
int h = getVarOrDirectWord(PARAM_2);
|
||||
// restoreCharsetBg(xpos, xpos + w, ypos, ypos + h)
|
||||
error("ScummEngine_v5::decodeParseString: Unhandled case 3: %d, %d", w, h);
|
||||
}
|
||||
break;
|
||||
case 4: // SO_CENTER
|
||||
@ -2652,10 +2653,7 @@ void ScummEngine_v5::decodeParseString() {
|
||||
break;
|
||||
case 6: // SO_LEFT
|
||||
if (_version == 3) {
|
||||
// FIXME: this value seems to be some kind of override
|
||||
// for text spacing?!?
|
||||
/* int a = */ getVarOrDirectWord(PARAM_1);
|
||||
|
||||
_string[textSlot].height = getVarOrDirectWord(PARAM_1);
|
||||
} else {
|
||||
_string[textSlot].center = false;
|
||||
_string[textSlot].overhead = false;
|
||||
@ -2715,6 +2713,7 @@ void ScummEngine_v5::decodeParseString() {
|
||||
if (_version <= 3) {
|
||||
_string[textSlot]._default.xpos = _string[textSlot].xpos;
|
||||
_string[textSlot]._default.ypos = _string[textSlot].ypos;
|
||||
_string[textSlot]._default.height = _string[textSlot].height;
|
||||
_string[textSlot]._default.color = _string[textSlot].color;
|
||||
}
|
||||
return;
|
||||
|
@ -1516,6 +1516,7 @@ void ScummEngine::scummInit() {
|
||||
_string[i]._default.ypos = 5;
|
||||
}
|
||||
_string[i]._default.right = _screenWidth - 1;
|
||||
_string[i]._default.height = 0;
|
||||
_string[i]._default.color = 0xF;
|
||||
_string[i]._default.center = 0;
|
||||
_string[i]._default.charset = 0;
|
||||
|
@ -249,6 +249,7 @@ struct StringSlot {
|
||||
int16 xpos;
|
||||
int16 ypos;
|
||||
int16 right;
|
||||
int16 height;
|
||||
byte color;
|
||||
byte charset;
|
||||
bool center;
|
||||
|
@ -234,7 +234,11 @@ void ScummEngine::CHARSET_1() {
|
||||
if (_charset->_center) {
|
||||
_charset->_nextLeft -= _charset->getStringWidth(0, buffer) / 2;
|
||||
}
|
||||
_charset->_nextTop += _charset->getFontHeight();
|
||||
if (_string[0].height) {
|
||||
_charset->_nextTop += _string[0].height;
|
||||
} else {
|
||||
_charset->_nextTop += _charset->getFontHeight();
|
||||
}
|
||||
if (_version > 3) {
|
||||
// FIXME - is this really needed?
|
||||
_charset->_disableOffsX = true;
|
||||
|
Loading…
x
Reference in New Issue
Block a user