diff options
Diffstat (limited to 'engines/titanic/game/play_on_act.cpp')
-rw-r--r-- | engines/titanic/game/play_on_act.cpp | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/engines/titanic/game/play_on_act.cpp b/engines/titanic/game/play_on_act.cpp index e1ef1201c6..9c368c335d 100644 --- a/engines/titanic/game/play_on_act.cpp +++ b/engines/titanic/game/play_on_act.cpp @@ -24,6 +24,11 @@ namespace Titanic { +BEGIN_MESSAGE_MAP(CPlayOnAct, CBackground) + ON_MESSAGE(ActMsg) + ON_MESSAGE(LeaveViewMsg) +END_MESSAGE_MAP() + void CPlayOnAct::save(SimpleFile *file, int indent) { file->writeNumberLine(1, indent); CBackground::save(file, indent); @@ -34,4 +39,20 @@ void CPlayOnAct::load(SimpleFile *file) { CBackground::load(file); } +bool CPlayOnAct::ActMsg(CActMsg *msg) { + if (msg->_action == "PlayMovie") { + setVisible(true); + playMovie(0); + } else if (msg->_action == "PlayToEnd") { + setVisible(true); + playMovie(MOVIE_GAMESTATE); + } + + return true; +} + +bool CPlayOnAct::LeaveViewMsg(CLeaveViewMsg *msg) { + return true; +} + } // End of namespace Titanic |