From f9422fb7260b8e5f0f45b93f22e0e4504a9e140b Mon Sep 17 00:00:00 2001 From: Sylvain Dupont Date: Fri, 21 Jan 2011 23:24:17 +0000 Subject: TOON: Bug #3153351 fixed with disappearing Drew Bug #3153351: "TOON: Drew vanishes when fixing churnatron" Made sure the scale is never zero. svn-id: r55399 --- engines/toon/drew.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'engines/toon/drew.cpp') diff --git a/engines/toon/drew.cpp b/engines/toon/drew.cpp index 1d4df09027..36ca17dd70 100644 --- a/engines/toon/drew.cpp +++ b/engines/toon/drew.cpp @@ -52,7 +52,9 @@ void CharacterDrew::setPosition(int32 x, int32 y) { debugC(5, kDebugCharacter, "setPosition(%d, %d)", x, y); _z = _vm->getLayerAtPoint(x, y); - _scale = _vm->getScaleAtPoint(x, y); + int newScale = _vm->getScaleAtPoint(x, y); + if (newScale > 0) + _scale = newScale; // work out position and scale of the character sprite int32 width = _walkAnim->getWidth() * _scale / 1024; -- cgit v1.2.3