diff options
author | Max Horn | 2002-05-19 12:39:52 +0000 |
---|---|---|
committer | Max Horn | 2002-05-19 12:39:52 +0000 |
commit | 92328dde8978e370851ee610e880d808d8bad84d (patch) | |
tree | ddb6237cc9dc34a226de753080c8e992fb7f3587 | |
parent | d2398b4b7e664dd174b4dcb827d83ccb8cfc3613 (diff) | |
download | scummvm-rg350-92328dde8978e370851ee610e880d808d8bad84d.tar.gz scummvm-rg350-92328dde8978e370851ee610e880d808d8bad84d.tar.bz2 scummvm-rg350-92328dde8978e370851ee610e880d808d8bad84d.zip |
use memset to init members to 0 (yes I know we override new to use calloc, but that is a nasty hack, it won't work for stack allocated objects)
svn-id: r4355
-rw-r--r-- | actor.h | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -24,6 +24,7 @@ #ifndef ACTOR_H #define ACTOR_H +#include <string.h> #include "scummsys.h" class Scumm; @@ -93,8 +94,8 @@ protected: public: - // Constructor - //Actor(Scumm *scumm) : _scumm(scumm) {} + // Constructor, sets all data to 0 + Actor() { memset(this, 0, sizeof(Actor)); } void initActorClass(Scumm *scumm) {_scumm = scumm;} //protected: void hideActor(); |