aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorTravis Howell2006-04-24 06:01:51 +0000
committerTravis Howell2006-04-24 06:01:51 +0000
commit1fa5c82301b49972ab23a5f4e11063977cb77f7d (patch)
treeaf6467f932e4491f684e752f89371cc717af5ca0 /engines
parent7f0fdde6d473726a8da5aa4f0e5aa14c1dc0783e (diff)
downloadscummvm-rg350-1fa5c82301b49972ab23a5f4e11063977cb77f7d.tar.gz
scummvm-rg350-1fa5c82301b49972ab23a5f4e11063977cb77f7d.tar.bz2
scummvm-rg350-1fa5c82301b49972ab23a5f4e11063977cb77f7d.zip
Initialize all variables in MoviePlayer class
svn-id: r22132
Diffstat (limited to 'engines')
-rw-r--r--engines/simon/animation.cpp26
1 files changed, 24 insertions, 2 deletions
diff --git a/engines/simon/animation.cpp b/engines/simon/animation.cpp
index fa457f68d8..e723d76282 100644
--- a/engines/simon/animation.cpp
+++ b/engines/simon/animation.cpp
@@ -41,6 +41,27 @@ namespace Simon {
MoviePlayer::MoviePlayer(SimonEngine *vm, Audio::Mixer *mixer)
: _vm(vm), _mixer(mixer) {
+ _frameNum = 0;
+ _frameSkipped = 0;
+
+ _playing = false;
+ _leftButtonDown = false;
+ _rightButtonDown = false;
+
+ _frameBuffer1 = 0;
+ _frameBuffer2 = 0;
+
+ _width = 0;
+ _height = 0;
+
+ _frameSize = 0;
+ _framesCount = 0;
+ _frameNum = 0;
+ _frameRate = 0;
+ _frameTicks = 0;
+ _frameSkipped = 0;
+
+ _ticks = 0;
}
MoviePlayer::~MoviePlayer() {
@@ -83,6 +104,9 @@ bool MoviePlayer::load(const char *filename) {
error("error allocating frame tables, size %d\n", _frameSize);
}
+ _frameNum = 0;
+ _frameSkipped = 0;
+
return true;
}
@@ -100,8 +124,6 @@ void MoviePlayer::play() {
_mixer->stopAll();
- _frameNum = 0;
-
_leftButtonDown = false;
_rightButtonDown = false;