MORTEVIELLE: Put resolution scaler in a const, remove some dead code related to it

This commit is contained in:
Strangerke 2013-08-16 19:23:29 +02:00
parent 481aeb0b0b
commit 9dd65e5ef3
9 changed files with 56 additions and 110 deletions

View file

@ -1408,7 +1408,7 @@ void MortevielleEngine::fctDiscuss() {
return; return;
_mouse.getMousePosition(x, y, click); _mouse.getMousePosition(x, y, click);
x *= (3 - _resolutionScaler); x *= (3 - kResolutionScaler);
if (x > 319) if (x > 319)
cx = 41; cx = 41;
else else

View file

@ -71,10 +71,7 @@ int DialogManager::show(const Common::String &msg, int n) {
while ((alertStr[i + 1] != '\174') && (alertStr[i + 1] != '\135')) { while ((alertStr[i + 1] != '\174') && (alertStr[i + 1] != '\135')) {
++i; ++i;
displayStr += alertStr[i]; displayStr += alertStr[i];
if (_vm->_resolutionScaler == 2) curPos.x -= 3;
curPos.x -= 3;
else
curPos.x -= 5;
} }
_vm->_screenSurface.putxy(curPos.x, _vm->_screenSurface._textPos.y); _vm->_screenSurface.putxy(curPos.x, _vm->_screenSurface._textPos.y);
_vm->_screenSurface._textPos.y += 6; _vm->_screenSurface._textPos.y += 6;
@ -95,12 +92,12 @@ int DialogManager::show(const Common::String &msg, int n) {
int limit[3][3]; int limit[3][3];
memset(&limit[0][0], 0, sizeof(int) * 3 * 3); memset(&limit[0][0], 0, sizeof(int) * 3 * 3);
limit[1][1] = ((uint)(coldep) / 2) * _vm->_resolutionScaler; limit[1][1] = ((uint)(coldep) / 2) * kResolutionScaler;
limit[1][2] = limit[1][1] + 40; limit[1][2] = limit[1][1] + 40;
if (caseNumb == 1) { if (caseNumb == 1) {
limit[2][1] = limit[2][2]; limit[2][1] = limit[2][2];
} else { } else {
limit[2][1] = ((uint)(320 + ((uint)esp >> 1)) / 2) * _vm->_resolutionScaler; limit[2][1] = ((uint)(320 + ((uint)esp >> 1)) / 2) * kResolutionScaler;
limit[2][2] = (limit[2][1]) + 40; limit[2][2] = (limit[2][1]) + 40;
} }
_vm->_mouse.showMouse(); _vm->_mouse.showMouse();
@ -221,10 +218,7 @@ void DialogManager::decodeAlertDetails(Common::String inputStr, int &choiceNumb,
} }
choiceListStr = Common::String(inputStr.c_str() + i); choiceListStr = Common::String(inputStr.c_str() + i);
if (_vm->_resolutionScaler == 2) col *= 6;
col *= 6;
else
col *= 10;
} }
void DialogManager::setPosition(int ji, int coldep, int esp) { void DialogManager::setPosition(int ji, int coldep, int esp) {
@ -302,11 +296,7 @@ bool DialogManager::showKnowledgeCheck() {
_vm->_mouse.hideMouse(); _vm->_mouse.hideMouse();
_vm->clearScreen(); _vm->clearScreen();
_vm->_mouse.showMouse(); _vm->_mouse.showMouse();
int dialogHeight; int dialogHeight = 23;
if (_vm->_resolutionScaler == 1)
dialogHeight = 29;
else
dialogHeight = 23;
_vm->_screenSurface.fillRect(15, Common::Rect(0, 14, 630, dialogHeight)); _vm->_screenSurface.fillRect(15, Common::Rect(0, 14, 630, dialogHeight));
Common::String tmpStr = _vm->getString(textIndexArr[indx]); Common::String tmpStr = _vm->getString(textIndexArr[indx]);
_vm->_text.displayStr(tmpStr, 20, 15, 100, 2, 0); _vm->_text.displayStr(tmpStr, 20, 15, 100, 2, 0);
@ -335,7 +325,7 @@ bool DialogManager::showKnowledgeCheck() {
} }
for (int j = 1; j <= lastOption - firstOption + 1; ++j) { for (int j = 1; j <= lastOption - firstOption + 1; ++j) {
coor[j]._rect = Common::Rect(45 * _vm->_resolutionScaler, 27 + j * 8, (maxLength * 3 + 55) * _vm->_resolutionScaler, 34 + j * 8); coor[j]._rect = Common::Rect(45 * kResolutionScaler, 27 + j * 8, (maxLength * 3 + 55) * kResolutionScaler, 34 + j * 8);
coor[j]._enabled = true; coor[j]._enabled = true;
while ((int)choiceArray[j].size() < maxLength) { while ((int)choiceArray[j].size() < maxLength) {
@ -343,11 +333,7 @@ bool DialogManager::showKnowledgeCheck() {
} }
} }
coor[lastOption - firstOption + 2]._enabled = false; coor[lastOption - firstOption + 2]._enabled = false;
int rep; int rep = 6;
if (_vm->_resolutionScaler == 1)
rep = 10;
else
rep = 6;
_vm->_screenSurface.drawBox(80, 33, 40 + (maxLength * rep), (lastOption - firstOption) * 8 + 16, 15); _vm->_screenSurface.drawBox(80, 33, 40 + (maxLength * rep), (lastOption - firstOption) * 8 + 16, 15);
rep = 0; rep = 0;
@ -477,7 +463,7 @@ void DialogManager::displayIntroFrame2() {
_vm->displayPicture(&_vm->_curAnim[_vm->_crep], 63, 12); _vm->displayPicture(&_vm->_curAnim[_vm->_crep], 63, 12);
_vm->_crep = _vm->getAnimOffset(2, 1); _vm->_crep = _vm->getAnimOffset(2, 1);
_vm->displayPicture(&_vm->_curAnim[_vm->_crep], 63, 12); _vm->displayPicture(&_vm->_curAnim[_vm->_crep], 63, 12);
_vm->_largestClearScreen = (_vm->_resolutionScaler == 1); _vm->_largestClearScreen = false;
_vm->handleDescriptionText(2, kDialogStringIndex + 143); _vm->handleDescriptionText(2, kDialogStringIndex + 143);
} }

View file

@ -1015,11 +1015,6 @@ void ScreenSurface::writeCharacter(const Common::Point &pt, unsigned char ch, in
* simulate the original 640x400 surface, all Y values have to be doubled * simulate the original 640x400 surface, all Y values have to be doubled
*/ */
void ScreenSurface::drawBox(int x, int y, int dx, int dy, int col) { void ScreenSurface::drawBox(int x, int y, int dx, int dy, int col) {
if (_vm->_resolutionScaler == 1) {
x = (uint)x >> 1;
dx = (uint)dx >> 1;
}
Graphics::Surface destSurface = lockArea(Common::Rect(x, y * 2, x + dx, (y + dy) * 2)); Graphics::Surface destSurface = lockArea(Common::Rect(x, y * 2, x + dx, (y + dy) * 2));
destSurface.hLine(0, 0, dx, col); destSurface.hLine(0, 0, dx, col);
@ -1078,11 +1073,7 @@ void ScreenSurface::drawString(const Common::String &l, int command) {
_vm->_mouse.hideMouse(); _vm->_mouse.hideMouse();
Common::Point pt = _textPos; Common::Point pt = _textPos;
int charWidth; int charWidth = 6;
if (_vm->_resolutionScaler == 2)
charWidth = 6;
else
charWidth = 10;
int x = pt.x + charWidth * l.size(); int x = pt.x + charWidth * l.size();
int color = 0; int color = 0;
@ -1118,7 +1109,7 @@ void ScreenSurface::drawString(const Common::String &l, int command) {
* Gets the width in pixels of the specified string * Gets the width in pixels of the specified string
*/ */
int ScreenSurface::getStringWidth(const Common::String &s) { int ScreenSurface::getStringWidth(const Common::String &s) {
int charWidth = (_vm->_resolutionScaler == 2) ? 6 : 10; int charWidth = 6;
return s.size() * charWidth; return s.size() * charWidth;
} }

View file

@ -271,7 +271,7 @@ void Menu::displayMenu() {
_vm->_mouse.hideMouse(); _vm->_mouse.hideMouse();
_vm->_screenSurface.fillRect(7, Common::Rect(0, 0, 639, 10)); _vm->_screenSurface.fillRect(7, Common::Rect(0, 0, 639, 10));
int col = 28 * _vm->_resolutionScaler; int col = 28 * kResolutionScaler;
for (int charNum = 0; charNum < 6; charNum++) { for (int charNum = 0; charNum < 6; charNum++) {
// One character after the other // One character after the other
int idx = 0; int idx = 0;
@ -293,7 +293,7 @@ void Menu::displayMenu() {
++idx; ++idx;
} }
} }
col += 48 * _vm->_resolutionScaler; col += 48 * kResolutionScaler;
} }
_vm->_mouse.showMouse(); _vm->_mouse.showMouse();
} }
@ -370,16 +370,12 @@ void Menu::util(Common::Point pos) {
int ymx = (menuConstants[_msg3 - 1][3] << 3) + 16; int ymx = (menuConstants[_msg3 - 1][3] << 3) + 16;
int dxcar = menuConstants[_msg3 - 1][2]; int dxcar = menuConstants[_msg3 - 1][2];
int xmn = (menuConstants[_msg3 - 1][0] << 2) * _vm->_resolutionScaler; int xmn = (menuConstants[_msg3 - 1][0] << 2) * kResolutionScaler;
int ix; int charWidth = 6;
if (_vm->_resolutionScaler == 1) int xmx = dxcar * charWidth + xmn + 2;
ix = 5;
else
ix = 3;
int xmx = dxcar * ix * _vm->_resolutionScaler + xmn + 2;
if ((pos.x > xmn) && (pos.x < xmx) && (pos.y < ymx) && (pos.y > 15)) { if ((pos.x > xmn) && (pos.x < xmx) && (pos.y < ymx) && (pos.y > 15)) {
ix = (((uint)pos.y >> 3) - 1) + (_msg3 << 8); int ix = (((uint)pos.y >> 3) - 1) + (_msg3 << 8);
if (ix != _msg4) { if (ix != _msg4) {
invert(1); invert(1);
_msg4 = ix; _msg4 = ix;
@ -402,11 +398,7 @@ void Menu::menuDown(int ii) {
int minX = menuConstants[ii - 1][0] << 3; int minX = menuConstants[ii - 1][0] << 3;
int lineNum = menuConstants[ii - 1][3]; int lineNum = menuConstants[ii - 1][3];
_vm->_mouse.hideMouse(); _vm->_mouse.hideMouse();
int deltaX; int deltaX = 6;
if (_vm->_resolutionScaler == 1)
deltaX = 10;
else
deltaX = 6;
int maxX = minX + (menuConstants[ii - 1][2] * deltaX) + 6; int maxX = minX + (menuConstants[ii - 1][2] * deltaX) + 6;
if ((ii == 4) && (_vm->getLanguage() == Common::EN_ANY)) if ((ii == 4) && (_vm->getLanguage() == Common::EN_ANY))
// Extra width needed for Self menu in English version // Extra width needed for Self menu in English version
@ -512,24 +504,24 @@ void Menu::updateMenu() {
_vm->_prevPos = curPos; _vm->_prevPos = curPos;
bool tes = (curPos.y < 11) bool tes = (curPos.y < 11)
&& ((curPos.x >= (28 * _vm->_resolutionScaler) && curPos.x <= (28 * _vm->_resolutionScaler + 24)) && ((curPos.x >= (28 * kResolutionScaler) && curPos.x <= (28 * kResolutionScaler + 24))
|| (curPos.x >= (76 * _vm->_resolutionScaler) && curPos.x <= (76 * _vm->_resolutionScaler + 24)) || (curPos.x >= (76 * kResolutionScaler) && curPos.x <= (76 * kResolutionScaler + 24))
|| ((curPos.x > 124 * _vm->_resolutionScaler) && (curPos.x < 124 * _vm->_resolutionScaler + 24)) || ((curPos.x > 124 * kResolutionScaler) && (curPos.x < 124 * kResolutionScaler + 24))
|| ((curPos.x > 172 * _vm->_resolutionScaler) && (curPos.x < 172 * _vm->_resolutionScaler + 24)) || ((curPos.x > 172 * kResolutionScaler) && (curPos.x < 172 * kResolutionScaler + 24))
|| ((curPos.x > 220 * _vm->_resolutionScaler) && (curPos.x < 220 * _vm->_resolutionScaler + 24)) || ((curPos.x > 220 * kResolutionScaler) && (curPos.x < 220 * kResolutionScaler + 24))
|| ((curPos.x > 268 * _vm->_resolutionScaler) && (curPos.x < 268 * _vm->_resolutionScaler + 24))); || ((curPos.x > 268 * kResolutionScaler) && (curPos.x < 268 * kResolutionScaler + 24)));
if (tes) { if (tes) {
int ix; int ix;
if (curPos.x < 76 * _vm->_resolutionScaler) if (curPos.x < 76 * kResolutionScaler)
ix = MENU_INVENTORY; ix = MENU_INVENTORY;
else if (curPos.x < 124 * _vm->_resolutionScaler) else if (curPos.x < 124 * kResolutionScaler)
ix = MENU_MOVE; ix = MENU_MOVE;
else if (curPos.x < 172 * _vm->_resolutionScaler) else if (curPos.x < 172 * kResolutionScaler)
ix = MENU_ACTION; ix = MENU_ACTION;
else if (curPos.x < 220 * _vm->_resolutionScaler) else if (curPos.x < 220 * kResolutionScaler)
ix = MENU_SELF; ix = MENU_SELF;
else if (curPos.x < 268 * _vm->_resolutionScaler) else if (curPos.x < 268 * kResolutionScaler)
ix = MENU_DISCUSS; ix = MENU_DISCUSS;
else else
ix = MENU_FILE; ix = MENU_FILE;

View file

@ -178,9 +178,6 @@ Common::ErrorCode MortevielleEngine::initialize() {
// Set up an intermediate screen surface // Set up an intermediate screen surface
_screenSurface.create(SCREEN_WIDTH, SCREEN_HEIGHT, Graphics::PixelFormat::createFormatCLUT8()); _screenSurface.create(SCREEN_WIDTH, SCREEN_HEIGHT, Graphics::PixelFormat::createFormatCLUT8());
// Set the screen mode
_resolutionScaler = 2;
_txxFileFl = false; _txxFileFl = false;
// Load texts from TXX files // Load texts from TXX files
loadTexts(); loadTexts();

View file

@ -115,6 +115,7 @@ const int kMenuSelfStringIndex = 497;
const int kMenuSayStringIndex = 502; const int kMenuSayStringIndex = 502;
const int kMaxPatt = 20; const int kMaxPatt = 20;
const int kResolutionScaler = 2;
/* /*
9 "A glance at the forbidden$", 9 "A glance at the forbidden$",
18 "It's already open$", 18 "It's already open$",
@ -427,7 +428,6 @@ public:
int _caff; int _caff;
int _crep; int _crep;
int _resolutionScaler;
byte _destinationArray[7][25]; byte _destinationArray[7][25];
byte *_curPict; byte *_curPict;

View file

@ -65,8 +65,8 @@ void MouseHandler::showMouse() {
* @remarks Originally called 'pos_mouse' * @remarks Originally called 'pos_mouse'
*/ */
void MouseHandler::setMousePosition(Common::Point newPos) { void MouseHandler::setMousePosition(Common::Point newPos) {
if (newPos.x > 314 * _vm->_resolutionScaler) if (newPos.x > 314 * kResolutionScaler)
newPos.x = 314 * _vm->_resolutionScaler; newPos.x = 314 * kResolutionScaler;
else if (newPos.x < 0) else if (newPos.x < 0)
newPos.x = 0; newPos.x = 0;
if (newPos.y > 199) if (newPos.y > 199)
@ -138,16 +138,16 @@ void MouseHandler::moveMouse(bool &funct, char &key) {
cy = 190; cy = 190;
break; break;
case '9': case '9':
cx = 315 * _vm->_resolutionScaler; cx = 315 * kResolutionScaler;
cy = 1; cy = 1;
break; break;
case '3': case '3':
cy = 190; cy = 190;
cx = 315 * _vm->_resolutionScaler; cx = 315 * kResolutionScaler;
break; break;
case '5': case '5':
cy = 100; cy = 100;
cx = 155 * _vm->_resolutionScaler; cx = 155 * kResolutionScaler;
break; break;
case ' ': case ' ':
case '\15': case '\15':
@ -201,27 +201,27 @@ void MouseHandler::moveMouse(bool &funct, char &key) {
} }
break; break;
case 'I': case 'I':
cx = _vm->_resolutionScaler * 32; cx = kResolutionScaler * 32;
cy = 8; cy = 8;
break; break;
case 'D': case 'D':
cx = 80 * _vm->_resolutionScaler; cx = 80 * kResolutionScaler;
cy = 8; cy = 8;
break; break;
case 'A': case 'A':
cx = 126 * _vm->_resolutionScaler; cx = 126 * kResolutionScaler;
cy = 8; cy = 8;
break; break;
case 'S': case 'S':
cx = 174 * _vm->_resolutionScaler; cx = 174 * kResolutionScaler;
cy = 8; cy = 8;
break; break;
case 'P': case 'P':
cx = 222 * _vm->_resolutionScaler; cx = 222 * kResolutionScaler;
cy = 8; cy = 8;
break; break;
case 'F': case 'F':
cx = _vm->_resolutionScaler * 270; cx = kResolutionScaler * 270;
cy = 8; cy = 8;
break; break;
case '\23': case '\23':

View file

@ -53,7 +53,6 @@ int TextHandler::nextWord(int p, const char *ch, int &tab) {
* @remarks Originally called 'afftex' * @remarks Originally called 'afftex'
*/ */
void TextHandler::displayStr(Common::String inputStr, int x, int y, int dx, int dy, int typ) { void TextHandler::displayStr(Common::String inputStr, int x, int y, int dx, int dy, int typ) {
int tab;
Common::String s; Common::String s;
int i, j; int i, j;
@ -61,10 +60,7 @@ void TextHandler::displayStr(Common::String inputStr, int x, int y, int dx, int
inputStr += '$'; inputStr += '$';
_vm->_screenSurface.putxy(x, y); _vm->_screenSurface.putxy(x, y);
if (_vm->_resolutionScaler == 1) int tab = 6;
tab = 10;
else
tab = 6;
dx *= 6; dx *= 6;
dy *= 6; dy *= 6;
int xc = x; int xc = x;

View file

@ -1679,19 +1679,12 @@ void MortevielleEngine::clearVerbBar() {
* @remarks Originally called 'clsf10' * @remarks Originally called 'clsf10'
*/ */
void MortevielleEngine::clearUpperRightPart() { void MortevielleEngine::clearUpperRightPart() {
int x1, x2;
Common::String st; Common::String st;
_mouse.hideMouse(); _mouse.hideMouse();
if (_resolutionScaler == 1) {
x2 = 634;
x1 = 534;
} else {
x2 = 600;
x1 = 544;
}
// Clear ambiance description // Clear ambiance description
_screenSurface.fillRect(15, Common::Rect(x1, 93, x2, 98)); _screenSurface.fillRect(15, Common::Rect(600, 93, 544, 98));
if (_coreVar._faithScore < 33) if (_coreVar._faithScore < 33)
st = getEngineString(S_COOL); st = getEngineString(S_COOL);
else if (_coreVar._faithScore < 66) else if (_coreVar._faithScore < 66)
@ -1699,7 +1692,7 @@ void MortevielleEngine::clearUpperRightPart() {
else if (_coreVar._faithScore > 65) else if (_coreVar._faithScore > 65)
st = getEngineString(S_MALSAINE); st = getEngineString(S_MALSAINE);
x1 = 580 - (_screenSurface.getStringWidth(st) / 2); int x1 = 580 - (_screenSurface.getStringWidth(st) / 2);
_screenSurface.putxy(x1, 92); _screenSurface.putxy(x1, 92);
_screenSurface.drawString(st, 4); _screenSurface.drawString(st, 4);
@ -2170,7 +2163,7 @@ void MortevielleEngine::showTitleScreen() {
draw(0, 0); draw(0, 0);
Common::String cpr = "COPYRIGHT 1989 : LANKHOR"; Common::String cpr = "COPYRIGHT 1989 : LANKHOR";
_screenSurface.putxy(104 + 72 * _resolutionScaler, 185); _screenSurface.putxy(104 + 72 * kResolutionScaler, 185);
_screenSurface.drawString(cpr, 0); _screenSurface.drawString(cpr, 0);
} }
@ -2370,9 +2363,9 @@ void MortevielleEngine::drawClock() {
_screenSurface.drawRectangle(578, 114, 6, 18); _screenSurface.drawRectangle(578, 114, 6, 18);
if (_minute == 0) if (_minute == 0)
_screenSurface.drawLine(((uint)x >> 1) * _resolutionScaler, y, ((uint)x >> 1) * _resolutionScaler, (y - rg), 1); _screenSurface.drawLine(((uint)x >> 1) * kResolutionScaler, y, ((uint)x >> 1) * kResolutionScaler, (y - rg), 1);
else else
_screenSurface.drawLine(((uint)x >> 1) * _resolutionScaler, y, ((uint)x >> 1) * _resolutionScaler, (y + rg), 1); _screenSurface.drawLine(((uint)x >> 1) * kResolutionScaler, y, ((uint)x >> 1) * kResolutionScaler, (y + rg), 1);
int hour12 = _hour; int hour12 = _hour;
if (hour12 > 12) if (hour12 > 12)
@ -2380,7 +2373,7 @@ void MortevielleEngine::drawClock() {
if (hour12 == 0) if (hour12 == 0)
hour12 = 12; hour12 = 12;
_screenSurface.drawLine(((uint)x >> 1) * _resolutionScaler, y, ((uint)(x + cv[0][hour12 - 1]) >> 1) * _resolutionScaler, y + cv[1][hour12 - 1], 1); _screenSurface.drawLine(((uint)x >> 1) * kResolutionScaler, y, ((uint)(x + cv[0][hour12 - 1]) >> 1) * kResolutionScaler, y + cv[1][hour12 - 1], 1);
_mouse.showMouse(); _mouse.showMouse();
_screenSurface.putxy(568, 154); _screenSurface.putxy(568, 154);
@ -2512,14 +2505,8 @@ int MortevielleEngine::getAnimOffset(int frameNum, int animNum) {
* @remarks Originally called 'text1' * @remarks Originally called 'text1'
*/ */
void MortevielleEngine::displayTextInDescriptionBar(int x, int y, int nb, int mesgId) { void MortevielleEngine::displayTextInDescriptionBar(int x, int y, int nb, int mesgId) {
int co;
if (_resolutionScaler == 1)
co = 10;
else
co = 6;
Common::String tmpStr = getString(mesgId); Common::String tmpStr = getString(mesgId);
if ((y == 182) && ((int) tmpStr.size() * co > nb * 6)) if ((y == 182) && ((int) tmpStr.size() > nb))
y = 176; y = 176;
_text.displayStr(tmpStr, x, y, nb, 20, _textColor); _text.displayStr(tmpStr, x, y, nb, 20, _textColor);
} }
@ -2532,7 +2519,7 @@ void MortevielleEngine::handleDescriptionText(int f, int mesgId) {
if ((mesgId > 499) && (mesgId < 563)) { if ((mesgId > 499) && (mesgId < 563)) {
Common::String tmpStr = getString(mesgId - 501 + kInventoryStringIndex); Common::String tmpStr = getString(mesgId - 501 + kInventoryStringIndex);
if ((int) tmpStr.size() > ((58 + (_resolutionScaler - 1) * 37) << 1)) if ((int) tmpStr.size() > ((58 + (kResolutionScaler - 1) * 37) << 1))
_largestClearScreen = true; _largestClearScreen = true;
else else
_largestClearScreen = false; _largestClearScreen = false;
@ -2641,7 +2628,7 @@ void MortevielleEngine::resetOpenObjects() {
void MortevielleEngine::displayTextBlock(Common::String text) { void MortevielleEngine::displayTextBlock(Common::String text) {
// Some dead code was present in the original: removed // Some dead code was present in the original: removed
_screenSurface.putxy(8, 177); _screenSurface.putxy(8, 177);
int tlig = 59 + (_resolutionScaler - 1) * 36; int tlig = 59 + (kResolutionScaler - 1) * 36;
if ((int)text.size() < tlig) if ((int)text.size() < tlig)
_screenSurface.drawString(text, 5); _screenSurface.drawString(text, 5);
@ -2867,10 +2854,7 @@ int MortevielleEngine::getPresence(int roomId) {
* @remarks Originally called 'writetp' * @remarks Originally called 'writetp'
*/ */
void MortevielleEngine::displayQuestionText(Common::String s, int cmd) { void MortevielleEngine::displayQuestionText(Common::String s, int cmd) {
if (_resolutionScaler == 2) _screenSurface.drawString(s, cmd);
_screenSurface.drawString(s, cmd);
else
_screenSurface.drawString(copy(s, 1, 25), cmd);
} }
/** /**
@ -3239,7 +3223,7 @@ void MortevielleEngine::displayStatusArrow() {
return; return;
if (getMouseClick()) if (getMouseClick())
inRect = (_mouse._pos.x < 256 * _resolutionScaler) && (_mouse._pos.y < 176) && (_mouse._pos.y > 12); inRect = (_mouse._pos.x < 256 * kResolutionScaler) && (_mouse._pos.y < 176) && (_mouse._pos.y > 12);
prepareRoom(); prepareRoom();
} while (!(qust || inRect || _anyone)); } while (!(qust || inRect || _anyone));
@ -3296,10 +3280,10 @@ void MortevielleEngine::setCoordinates(int sx) {
cy = 1; cy = 1;
do { do {
cb += 2; cb += 2;
sx = _tabdon[a + cb] * _resolutionScaler; sx = _tabdon[a + cb] * kResolutionScaler;
sy = _tabdon[(a + cb + 1)]; sy = _tabdon[(a + cb + 1)];
cb += 2; cb += 2;
ix = _tabdon[a + cb] * _resolutionScaler; ix = _tabdon[a + cb] * kResolutionScaler;
iy = _tabdon[(a + cb + 1)]; iy = _tabdon[(a + cb + 1)];
++cy; ++cy;
} while (!(((_x >= sx) && (_x <= ix) && (_y >= sy) && (_y <= iy)) || (cy > ib))); } while (!(((_x >= sx) && (_x <= ix) && (_y >= sy) && (_y <= iy)) || (cy > ib)));