aboutsummaryrefslogtreecommitdiff
path: root/engines/scumm/script_v2.cpp
diff options
context:
space:
mode:
authorTorbjörn Andersson2006-05-14 10:40:06 +0000
committerTorbjörn Andersson2006-05-14 10:40:06 +0000
commit16b7c74cc4fa4b36102b0d2e0195ee48e740cdae (patch)
treed99196a1249c702116a57b0fefb575f157f35c31 /engines/scumm/script_v2.cpp
parentbb9de08c7354025bc2b074a6e13ddbe5cc0d5e7f (diff)
downloadscummvm-rg350-16b7c74cc4fa4b36102b0d2e0195ee48e740cdae.tar.gz
scummvm-rg350-16b7c74cc4fa4b36102b0d2e0195ee48e740cdae.tar.bz2
scummvm-rg350-16b7c74cc4fa4b36102b0d2e0195ee48e740cdae.zip
Cleanup.
svn-id: r22468
Diffstat (limited to 'engines/scumm/script_v2.cpp')
-rw-r--r--engines/scumm/script_v2.cpp14
1 files changed, 5 insertions, 9 deletions
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);