diff options
Diffstat (limited to 'engines/m4/m4_scene.cpp')
-rw-r--r-- | engines/m4/m4_scene.cpp | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/engines/m4/m4_scene.cpp b/engines/m4/m4_scene.cpp index 90f288c31a..fcbf2b0dd7 100644 --- a/engines/m4/m4_scene.cpp +++ b/engines/m4/m4_scene.cpp @@ -41,8 +41,10 @@ namespace M4 { M4Scene::M4Scene(M4Engine *vm): _sceneResources(), Scene(vm, &_sceneResources) { _vm = vm; _sceneSprites = NULL; - _interfaceSurface = new M4InterfaceView(vm); _inverseColourTable = NULL; + + _sceneResources.parallax = new HotSpotList(); + _interfaceSurface = new M4InterfaceView(vm); } M4Scene::~M4Scene() { @@ -195,6 +197,9 @@ void M4Scene::show() { } void M4Scene::leaveScene() { + _sceneResources.parallax->clear(); + + delete _sceneResources.parallax; delete[] _inverseColourTable; Scene::leaveScene(); @@ -308,4 +313,14 @@ void M4Scene::nextCommonCursor() { _vm->_mouse->setCursorNum(cursorIndex); } +void M4Scene::showHotSpots() { + Scene::showHotSpots(); + + // parallax (yellow) + for (int i = 0; i < _sceneResources.parallaxCount; i++) { + HotSpot *currentHotSpot = _sceneResources.parallax->get(i); + _backgroundSurface->frameRect(currentHotSpot->getRect(), _vm->_palette->YELLOW); + } +} + } // End of namespace M4 |