SCUMM: Fix X-range of selection for Hebrew on scumm<7
curRect.left is assigned in the script, and it is not modified. right is
assigned with the screen width - original left.
This results in bad highlighting of the verbs all over the line width,
instead of being limited to the actual string.
Due to that, sometimes the selection range of the up/down arrows overlaps
with some of the verbs, and then these verbs cannot be selected.
Solve by storing the original left value, and using it as initial x
position for the string (the actual right-to-left manipulation is done in
drawString()), and modify the value of curRect.left to match the string
that was actually drawn.
This bug is similar to the one that was fixed in 58e921eb87
, but the
solution that was done there for v7 and v8 cannot work here, because the
string logic is much more complicated.
This commit is contained in:
parent
ae1016e5c2
commit
c8fc484c37
7 changed files with 13 additions and 9 deletions
|
@ -2304,7 +2304,7 @@ void ScummEngine_v5::o5_verbOps() {
|
|||
vs->hicolor = getVarOrDirectByte(PARAM_1);
|
||||
break;
|
||||
case 5: // SO_VERB_AT
|
||||
vs->curRect.left = getVarOrDirectWord(PARAM_1);
|
||||
vs->curRect.left = vs->origLeft = getVarOrDirectWord(PARAM_1);
|
||||
vs->curRect.top = getVarOrDirectWord(PARAM_2);
|
||||
// Macintosh version of indy3ega used different interface, so adjust values.
|
||||
if ((_game.platform == Common::kPlatformMacintosh) && (_game.id == GID_INDY3)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue