mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-15 06:08:35 +00:00
SHERLOCK: RT: Fix loading and display of journal locations
This commit is contained in:
parent
6ff53ea018
commit
d021b20e82
@ -245,7 +245,7 @@ bool Journal::drawJournal(int direction, int howFar) {
|
||||
Common::String lineStart(_lines[temp].c_str(), matchP);
|
||||
if (lineStart.hasPrefix("@")) {
|
||||
width = screen.stringWidth(lineStart.c_str() + 1);
|
||||
screen.gPrint(Common::Point(JOURNAL_LEFT_X, yp), 15, "%s", lineStart.c_str() + 1);
|
||||
screen.gPrint(Common::Point(JOURNAL_LEFT_X, yp), COL_PEN_HIGHLIGHT, "%s", lineStart.c_str() + 1);
|
||||
} else {
|
||||
width = screen.stringWidth(lineStart.c_str());
|
||||
screen.gPrint(Common::Point(JOURNAL_LEFT_X, yp), COL_PEN_COLOR, "%s", lineStart.c_str());
|
||||
@ -260,13 +260,13 @@ bool Journal::drawJournal(int direction, int howFar) {
|
||||
// Print remainder of line
|
||||
screen.gPrint(Common::Point(JOURNAL_LEFT_X + width, yp), COL_PEN_COLOR, "%s", matchP + _find.size());
|
||||
} else if (_lines[temp].hasPrefix("@")) {
|
||||
screen.gPrint(Common::Point(JOURNAL_LEFT_X, yp), 15, "%s", _lines[temp].c_str() + 1);
|
||||
screen.gPrint(Common::Point(JOURNAL_LEFT_X, yp), COL_PEN_HIGHLIGHT, "%s", _lines[temp].c_str() + 1);
|
||||
} else {
|
||||
screen.gPrint(Common::Point(JOURNAL_LEFT_X, yp), COL_PEN_COLOR, "%s", _lines[temp].c_str());
|
||||
}
|
||||
} else {
|
||||
if (_lines[temp].hasPrefix("@")) {
|
||||
screen.gPrint(Common::Point(JOURNAL_LEFT_X, yp), 15, "%s", _lines[temp].c_str() + 1);
|
||||
screen.gPrint(Common::Point(JOURNAL_LEFT_X, yp), COL_PEN_HIGHLIGHT, "%s", _lines[temp].c_str() + 1);
|
||||
} else {
|
||||
screen.gPrint(Common::Point(JOURNAL_LEFT_X, yp), COL_PEN_COLOR, "%s", _lines[temp].c_str());
|
||||
}
|
||||
|
@ -72,6 +72,7 @@ enum GameType {
|
||||
|
||||
#define COL_INFO_FOREGROUND (IS_SERRATED_SCALPEL ? (byte)Scalpel::INFO_FOREGROUND : (byte)Tattoo::INFO_FOREGROUND)
|
||||
#define COL_PEN_COLOR (IS_SERRATED_SCALPEL ? (byte)Scalpel::PEN_COLOR : (byte)Tattoo::PEN_COLOR)
|
||||
#define COL_PEN_HIGHLIGHT (IS_SERRATED_SCALPEL ? 15 : 129)
|
||||
|
||||
struct SherlockGameDescription;
|
||||
|
||||
|
@ -409,7 +409,7 @@ void TattooJournal::loadLocations() {
|
||||
locNumStr += line[i];
|
||||
i++;
|
||||
}
|
||||
locNum = atoi(locNumStr.c_str());
|
||||
locNum = atoi(locNumStr.c_str()) - 1;
|
||||
|
||||
// Skip the dot, spaces and initial quotation mark
|
||||
while (line[i] == ' ' || line[i] == '.' || line[i] == '\"')
|
||||
|
Loading…
Reference in New Issue
Block a user