From 16b7c74cc4fa4b36102b0d2e0195ee48e740cdae Mon Sep 17 00:00:00 2001 From: Torbjörn Andersson Date: Sun, 14 May 2006 10:40:06 +0000 Subject: Cleanup. svn-id: r22468 --- engines/scumm/script_v2.cpp | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) (limited to 'engines/scumm/script_v2.cpp') diff --git a/engines/scumm/script_v2.cpp b/engines/scumm/script_v2.cpp index 184f491079..fc9924ffca 100644 --- a/engines/scumm/script_v2.cpp +++ b/engines/scumm/script_v2.cpp @@ -415,10 +415,7 @@ void ScummEngine_v2::decodeParseString() { int textSlot = 0; _string[textSlot].xpos = 0; _string[textSlot].ypos = 0; - if (_game.platform == Common::kPlatformNES) - _string[textSlot].right = 256; - else - _string[textSlot].right = 320; + _string[textSlot].right = _screenWidth - 1; _string[textSlot].center = false; _string[textSlot].overhead = false; @@ -1069,7 +1066,7 @@ void ScummEngine_v2::o2_drawSentence() { int i = 0, len = 0; // Maximum length of printable characters - int maxChars = (_game.platform == Common::kPlatformNES) ? 60: 40; + int maxChars = (_game.platform == Common::kPlatformNES) ? 60 : 40; while (*ptr) { if (*ptr != '@') len++; @@ -1090,12 +1087,12 @@ void ScummEngine_v2::o2_drawSentence() { sentenceline.top = virtscr[kVerbVirtScreen].topline; sentenceline.bottom = virtscr[kVerbVirtScreen].topline + 16; sentenceline.left = 16; - sentenceline.right = 255; + sentenceline.right = virtscr[kVerbVirtScreen].w - 1; } else { sentenceline.top = virtscr[kVerbVirtScreen].topline; sentenceline.bottom = virtscr[kVerbVirtScreen].topline + 8; sentenceline.left = 0; - sentenceline.right = 319; + sentenceline.right = virtscr[kVerbVirtScreen].w - 1; } restoreBG(sentenceline); @@ -1585,12 +1582,11 @@ void ScummEngine_v2::setUserState(byte state) { Common::Rect rect; rect.top = virtscr[kVerbVirtScreen].topline; rect.bottom = virtscr[kVerbVirtScreen].topline + 8 * 88; + rect.right = virtscr[kVerbVirtScreen].w - 1; if (_game.platform == Common::kPlatformNES) { rect.left = 16; - rect.right = 255; } else { rect.left = 0; - rect.right = 319; } restoreBG(rect); -- cgit v1.2.3