SHERLOCK: Fix only first page of description being shown

When examining a room object with a description that spans multiple
pages, only the first page was shown if the inventory was open at the
same time. This bug happens in the original too. Hopefully fixing it
does not cause any unwanted side effects.
This commit is contained in:
Torbjörn Andersson 2021-12-10 09:34:14 +01:00 committed by Paul Gilbert
parent 70508052c6
commit 7de71dd342

View File

@ -1266,12 +1266,13 @@ void ScalpelUserInterface::doLookControl() {
_keyboardInput = (_keyPress != '\0');
if (events._released || events._rightReleased || _keyboardInput) {
// Is there any remaining text to display?
if (!_descStr.empty()) {
printObjectDesc(_descStr, false);
}
// Is an inventory object being looked at?
if (!_invLookFlag) {
// Is there any remaining text to display?
if (!_descStr.empty()) {
printObjectDesc(_descStr, false);
} else if (!_lookHelp) {
else if (!_invLookFlag) {
if (!_lookHelp) {
// Need to close the window and depress the Look button
Common::Point pt(MENU_POINTS[0][0], MENU_POINTS[0][1]);
offsetButton3DO(pt, 0);