aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLionel Ulmer2002-05-01 10:48:09 +0000
committerLionel Ulmer2002-05-01 10:48:09 +0000
commit38d7d2140dafbf897ccb0da1373405f56db402ca (patch)
tree7c8defebb5d35e5501d8d313b6690226fa9f0273
parentb955d7e5115d7a0eff039cf7d727d1555ea3e1fc (diff)
downloadscummvm-rg350-38d7d2140dafbf897ccb0da1373405f56db402ca.tar.gz
scummvm-rg350-38d7d2140dafbf897ccb0da1373405f56db402ca.tar.bz2
scummvm-rg350-38d7d2140dafbf897ccb0da1373405f56db402ca.zip
Another fix for LoomCD. Now Valgrind does not reports any error
anymore in LoomCD (well, with a small hack still active :-) ). svn-id: r4156
-rw-r--r--actor.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/actor.cpp b/actor.cpp
index 99b01a823f..896104acfb 100644
--- a/actor.cpp
+++ b/actor.cpp
@@ -919,17 +919,16 @@ void Scumm::drawActorCostume(Actor * a)
else if (g_scumm->getClass(a->number, 21))
a->forceClip = 1;
-
-
if (_gameId==GID_SAMNMAX && getState(995)) // FIXME: ugly fix for samnmax inventory
-
return;
-
a->needRedraw = false;
setupActorScale(a);
+ /* First, zero initialize all fields */
+ memset(&cr, 0, sizeof(cr));
+
cr._actorX = a->x - virtscr->xstart;
cr._actorY = a->y - a->elevation;
cr._scaleX = a->scalex;
@@ -969,6 +968,9 @@ void Scumm::drawActorCostume(Actor * a)
setupActorScale(a);
+ /* First, zero initialize all fields */
+ memset(&ar, 0, sizeof(ar));
+
ar.x = a->x - virtscr->xstart;
ar.y = a->y - a->elevation;
ar.scale_x = a->scalex;