diff options
author | Strangerke | 2015-12-24 02:03:00 +0100 |
---|---|---|
committer | Strangerke | 2015-12-24 02:03:00 +0100 |
commit | ba243ea58781a7f52ccee526655e305a3daacfbb (patch) | |
tree | c7ec730f46c8e54ffce0969a268f480ea2336010 /engines/lab | |
parent | f4bc3c0ab424ea5c7a123ad21814a6c0fae10847 (diff) | |
download | scummvm-rg350-ba243ea58781a7f52ccee526655e305a3daacfbb.tar.gz scummvm-rg350-ba243ea58781a7f52ccee526655e305a3daacfbb.tar.bz2 scummvm-rg350-ba243ea58781a7f52ccee526655e305a3daacfbb.zip |
LAB: Handle intro font in intro constructor and destructor
Diffstat (limited to 'engines/lab')
-rw-r--r-- | engines/lab/intro.cpp | 10 | ||||
-rw-r--r-- | engines/lab/intro.h | 1 |
2 files changed, 6 insertions, 5 deletions
diff --git a/engines/lab/intro.cpp b/engines/lab/intro.cpp index 7184d1093a..e5a41d6117 100644 --- a/engines/lab/intro.cpp +++ b/engines/lab/intro.cpp @@ -43,7 +43,11 @@ namespace Lab { Intro::Intro(LabEngine *vm) : _vm(vm) { _quitIntro = false; _introDoBlack = false; - _font = nullptr; + _font = _vm->_resource->getFont("F:Map.fon"); +} + +Intro::~Intro() { + _vm->_graphics->closeFont(&_font); } void Intro::introEatMessages() { @@ -316,8 +320,6 @@ void Intro::play() { _vm->_graphics->blackAllScreen(); _vm->updateMusicAndEvents(); - _font = _vm->_resource->getFont("F:Map.fon"); - _vm->_anim->_noPalChange = true; nReadPict("Intro.1"); _vm->_anim->_noPalChange = false; @@ -435,8 +437,6 @@ void Intro::play() { _vm->_graphics->rectFill(0, 0, _vm->_graphics->_screenWidth - 1, _vm->_graphics->_screenHeight - 1); _vm->_anim->_doBlack = true; } - - _vm->_graphics->closeFont(&_font); } } // End of namespace Lab diff --git a/engines/lab/intro.h b/engines/lab/intro.h index 991db2f3f4..9961be6226 100644 --- a/engines/lab/intro.h +++ b/engines/lab/intro.h @@ -36,6 +36,7 @@ namespace Lab { class Intro { public: Intro(LabEngine *vm); + ~Intro(); /** * Does the introduction sequence for Labyrinth. |