aboutsummaryrefslogtreecommitdiff
path: root/engines/mads/scene.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/mads/scene.cpp')
-rw-r--r--engines/mads/scene.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/engines/mads/scene.cpp b/engines/mads/scene.cpp
index cb68d38eec..ad24dd4f60 100644
--- a/engines/mads/scene.cpp
+++ b/engines/mads/scene.cpp
@@ -63,8 +63,7 @@ Scene::Scene(MADSEngine *vm)
_paletteUsageF.push_back(PaletteUsage::UsageEntry(0xF));
// Set up a scene surface that maps to our physical screen drawing surface
- _sceneSurface.init(MADS_SCREEN_WIDTH, MADS_SCENE_HEIGHT, MADS_SCREEN_WIDTH,
- _vm->_screen.getPixels(), Graphics::PixelFormat::createFormatCLUT8());
+ restrictScene();
// Set up the verb list
_verbList.push_back(VerbInit(VERB_LOOK, VERB_THAT, PREP_NONE));
@@ -85,6 +84,11 @@ Scene::~Scene() {
delete _animationData;
}
+void Scene::restrictScene() {
+ _sceneSurface.init(MADS_SCREEN_WIDTH, MADS_SCENE_HEIGHT, MADS_SCREEN_WIDTH,
+ _vm->_screen.getPixels(), Graphics::PixelFormat::createFormatCLUT8());
+}
+
void Scene::clearVocab() {
_activeVocabs.clear();
}
@@ -511,7 +515,7 @@ void Scene::drawElements(ScreenTransition transitionType, bool surfaceFlag) {
_vm->_sound->startQueuedCommands();
} else {
// Copy dirty areas to the screen
- _dirtyAreas.copyToScreen(_vm->_screen._offset);
+ _dirtyAreas.copyToScreen();
}
_spriteSlots.cleanUp();