From 212479ab79cfabade43222e1295aa402435d55d9 Mon Sep 17 00:00:00 2001 From: Paul Gilbert Date: Wed, 25 Aug 2010 06:42:54 +0000 Subject: M4: Implementation of script engine svn-id: r52364 --- engines/m4/mads_scene.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'engines/m4/mads_scene.cpp') diff --git a/engines/m4/mads_scene.cpp b/engines/m4/mads_scene.cpp index d44fa2a753..1ddbf89fed 100644 --- a/engines/m4/mads_scene.cpp +++ b/engines/m4/mads_scene.cpp @@ -68,6 +68,7 @@ MadsScene::MadsScene(MadsEngine *vm): _sceneResources(), Scene(vm, &_sceneResour _interfaceSurface = new MadsInterfaceView(vm); _showMousePos = false; _mouseMsgIndex = -1; + _previousScene = -1; } MadsScene::~MadsScene() { @@ -174,7 +175,7 @@ void MadsScene::loadScene(int sceneNumber) { // Do any scene specific setup if (_vm->getGameType() == GType_RexNebular) - _sceneLogic.enterScene(); + _sceneLogic.doEnterScene(); // Miscellaneous player setup _madsVm->_player._destPos = _madsVm->_player._destPos; -- cgit v1.2.3 From 4395e75aef8572ef3fa06fd44cd8129dea2d91c8 Mon Sep 17 00:00:00 2001 From: Paul Gilbert Date: Wed, 25 Aug 2010 06:55:11 +0000 Subject: M4: Fixes for compiler errors svn-id: r52365 --- engines/m4/mads_scene.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'engines/m4/mads_scene.cpp') diff --git a/engines/m4/mads_scene.cpp b/engines/m4/mads_scene.cpp index 1ddbf89fed..641ee756e3 100644 --- a/engines/m4/mads_scene.cpp +++ b/engines/m4/mads_scene.cpp @@ -62,6 +62,7 @@ void SceneNode::load(Common::SeekableReadStream *stream) { MadsScene::MadsScene(MadsEngine *vm): _sceneResources(), Scene(vm, &_sceneResources), MadsView(this) { _vm = vm; _activeAnimation = NULL; + _animActive = false; MadsView::_bgSurface = Scene::_backgroundSurface; MadsView::_depthSurface = Scene::_walkSurface; @@ -216,6 +217,7 @@ void MadsScene::leaveScene() { if (_activeAnimation) { delete _activeAnimation; _activeAnimation = NULL; + _animActive = false; } Scene::leaveScene(); @@ -384,6 +386,7 @@ void MadsScene::updateState() { if (((MadsAnimation *) _activeAnimation)->freeFlag() || freeFlag) { delete _activeAnimation; _activeAnimation = NULL; + _animActive = false; } } @@ -455,6 +458,7 @@ void MadsScene::freeAnimation() { delete _activeAnimation; _activeAnimation = NULL; + _animActive = false; } @@ -574,6 +578,7 @@ void MadsScene::loadAnimation(const Common::String &animName, int abortTimers) { MadsAnimation *anim = new MadsAnimation(_vm, this); anim->load(animName.c_str(), abortTimers); _activeAnimation = anim; + _animActive = true; } bool MadsScene::getDepthHighBit(const Common::Point &pt) { -- cgit v1.2.3