diff options
Diffstat (limited to 'engines')
-rw-r--r-- | engines/dreamweb/print.cpp | 4 | ||||
-rw-r--r-- | engines/dreamweb/stubs.cpp | 9 | ||||
-rw-r--r-- | engines/dreamweb/stubs.h | 1 | ||||
-rw-r--r-- | engines/dreamweb/use.cpp | 3 |
4 files changed, 8 insertions, 9 deletions
diff --git a/engines/dreamweb/print.cpp b/engines/dreamweb/print.cpp index c1dbfc0a87..b6ec95781d 100644 --- a/engines/dreamweb/print.cpp +++ b/engines/dreamweb/print.cpp @@ -138,6 +138,10 @@ void DreamGenContext::printdirect() { bx = y; } +void DreamGenContext::printdirect(const uint8* string, uint16 x, uint16 y, uint8 maxWidth, bool centered) { + printdirect(&string, x, &y, maxWidth, centered); +} + void DreamGenContext::printdirect(const uint8** string, uint16 x, uint16 *y, uint8 maxWidth, bool centered) { data.word(kLastxpos) = x; const Frame *charSet = (const Frame *)segRef(data.word(kCurrentset)).ptr(0, 0); diff --git a/engines/dreamweb/stubs.cpp b/engines/dreamweb/stubs.cpp index 034f794c29..7d4f05536d 100644 --- a/engines/dreamweb/stubs.cpp +++ b/engines/dreamweb/stubs.cpp @@ -1103,19 +1103,14 @@ void DreamGenContext::commandwithob(uint8 command, uint8 type, uint8 index) { uint16 commandText = kTextstart + segRef(data.word(kCommandtext)).word(command * 2); uint8 textLen = data.byte(kTextlen); { - uint16 y = data.word(kTextaddressy); const uint8 *string = segRef(data.word(kCommandtext)).ptr(commandText, 0); - printdirect(&string, data.word(kTextaddressx), &y, textLen, (bool)(textLen & 1)); + printdirect(string, data.word(kTextaddressx), data.word(kTextaddressy), textLen, (bool)(textLen & 1)); } copyname(type, index, commandLine); uint16 x = data.word(kLastxpos); if (command != 0) x += 5; - { - uint16 y = data.word(kTextaddressy); - const uint8 *string = commandLine; - printdirect(&string, x, &y, textLen, (bool)(textLen & 1)); - } + printdirect(commandLine, x, data.word(kTextaddressy), textLen, (bool)(textLen & 1)); data.byte(kNewtextline) = 1; } diff --git a/engines/dreamweb/stubs.h b/engines/dreamweb/stubs.h index 4a97fd22f5..66e32de3d7 100644 --- a/engines/dreamweb/stubs.h +++ b/engines/dreamweb/stubs.h @@ -47,6 +47,7 @@ void printchar(const Frame* charSet, uint16 *x, uint16 y, uint8 c, uint8 nextChar, uint8 *width, uint8 *height); void printdirect(); void printdirect(const uint8** string, uint16 x, uint16 *y, uint8 maxWidth, bool centered); + void printdirect(const uint8* string, uint16 x, uint16 y, uint8 maxWidth, bool centered); void printmessage(uint16 x, uint16 y, uint8 index, uint8 maxWidth, bool centered); void printmessage(); void usetimedtext(); diff --git a/engines/dreamweb/use.cpp b/engines/dreamweb/use.cpp index 38fac02c00..f584de254a 100644 --- a/engines/dreamweb/use.cpp +++ b/engines/dreamweb/use.cpp @@ -173,8 +173,7 @@ void DreamGenContext::usetext(const uint8 *string) { showman(); showexit(); obicons(); - uint16 y = 104; - printdirect(&string, 36, &y, 241, true); + printdirect(string, 36, 104, 241, true); worktoscreenm(); } |