mirror of
https://github.com/libretro/scummvm.git
synced 2025-02-09 04:16:34 +00:00
o5_getStringWidth was missing getResultPos() (thanks to _Q for pointing this out)
svn-id: r9441
This commit is contained in:
parent
ac2c77f601
commit
ffa32a2eca
@ -834,12 +834,15 @@ void Scumm_v5::o5_drawObject() {
|
|||||||
|
|
||||||
void Scumm_v5::o5_getStringWidth() {
|
void Scumm_v5::o5_getStringWidth() {
|
||||||
// TODO - not sure if this is correct... needs testing
|
// TODO - not sure if this is correct... needs testing
|
||||||
int a = getVarOrDirectByte(0x80);
|
int string, width = 0;
|
||||||
byte *ptr = getResourceAddress(rtString, a);
|
byte *ptr;
|
||||||
int width = 0;
|
|
||||||
|
|
||||||
if (ptr)
|
getResultPos();
|
||||||
width = _charset->getStringWidth(0, ptr);
|
string = getVarOrDirectByte(0x80);
|
||||||
|
ptr = getResourceAddress(rtString, string);
|
||||||
|
assert(ptr);
|
||||||
|
|
||||||
|
width = _charset->getStringWidth(0, ptr);
|
||||||
|
|
||||||
setResult(width);
|
setResult(width);
|
||||||
warning("o5_getStringWidth, result %d", width);
|
warning("o5_getStringWidth, result %d", width);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user