[Scummvm-cvs-logs] CVS: scummvm/scumm actor.cpp,1.143,1.143.2.1 actor.h,1.33,1.33.2.1

Max Horn fingolfin at users.sourceforge.net
Sun Jul 27 16:46:19 CEST 2003


Update of /cvsroot/scummvm/scummvm/scumm
In directory sc8-pr-cvs1:/tmp/cvs-serv17384

Modified Files:
      Tag: branch-0-5-0
	actor.cpp actor.h 
Log Message:
init walkdata (fix for bug #770306); move Actor::Actor constructor from header to source file

Index: actor.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/actor.cpp,v
retrieving revision 1.143
retrieving revision 1.143.2.1
diff -u -d -r1.143 -r1.143.2.1
--- actor.cpp	22 Jul 2003 20:53:01 -0000	1.143
+++ actor.cpp	27 Jul 2003 23:45:43 -0000	1.143.2.1
@@ -44,6 +44,29 @@
 	}
 }
 
+Actor::Actor() {
+	assert(_vm != 0);
+	top = bottom = 0;
+	number = 0;
+	needRedraw = needBgReset = costumeNeedsInit = visible = false;
+	flip = false;
+	speedx = 8;
+	speedy = 2;
+	frame = 0;
+	walkbox = 0;
+	animProgress = 0;
+	memset(animVariable, 0, sizeof(animVariable));
+	memset(palette, 0, sizeof(palette));
+	memset(sound, 0, sizeof(sound));
+	memset(&cost, 0, sizeof(CostumeData));
+	memset(&walkdata, 0, sizeof(ActorWalkData));
+	walkdata.point3x = 32000;
+
+	walkScript = 0;
+
+	initActor(1);
+}
+
 void Actor::initActor(int mode) {
 	if (mode == 1) {
 		costume = 0;

Index: actor.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/actor.h,v
retrieving revision 1.33
retrieving revision 1.33.2.1
diff -u -d -r1.33 -r1.33.2.1
--- actor.h	2 Jul 2003 13:47:02 -0000	1.33
+++ actor.h	27 Jul 2003 23:45:43 -0000	1.33.2.1
@@ -121,27 +121,7 @@
 
 public:
 
-	// Constructor, sets all data to 0
-	Actor() {
-		assert(_vm != 0);
-		top = bottom = 0;
-		number = 0;
-		needRedraw = needBgReset = costumeNeedsInit = visible = false;
-		flip = false;
-		speedx = 8;
-		speedy = 2;
-		frame = 0;
-		walkbox = 0;
-		animProgress = 0;
-		memset(animVariable, 0, sizeof(animVariable));
-		memset(palette, 0, sizeof(palette));
-		memset(sound, 0, sizeof(sound));
-		memset(&cost, 0, sizeof(CostumeData));
-
-		walkScript = 0;
-
-		initActor(1);
-	}
+	Actor();
 	
 //protected:
 	void hideActor();





More information about the Scummvm-git-logs mailing list