diff options
Diffstat (limited to 'engines/titanic/game/glass_smasher.cpp')
-rw-r--r-- | engines/titanic/game/glass_smasher.cpp | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/engines/titanic/game/glass_smasher.cpp b/engines/titanic/game/glass_smasher.cpp index 8c33124a47..2123f2dfd0 100644 --- a/engines/titanic/game/glass_smasher.cpp +++ b/engines/titanic/game/glass_smasher.cpp @@ -24,6 +24,11 @@ namespace Titanic { +BEGIN_MESSAGE_MAP(CGlassSmasher, CGameObject) + ON_MESSAGE(StatusChangeMsg) + ON_MESSAGE(MovieEndMsg) +END_MESSAGE_MAP() + void CGlassSmasher::save(SimpleFile *file, int indent) { file->writeNumberLine(1, indent); CGameObject::save(file, indent); @@ -34,4 +39,18 @@ void CGlassSmasher::load(SimpleFile *file) { CGameObject::load(file); } +bool CGlassSmasher::StatusChangeMsg(CStatusChangeMsg *msg) { + setVisible(true); + playSound("b#40.wav"); + playMovie(MOVIE_NOTIFY_OBJECT | MOVIE_GAMESTATE); + return true; +} + +bool CGlassSmasher::MovieEndMsg(CMovieEndMsg *msg) { + setVisible(false); + CVisibleMsg visibleMsg(true); + visibleMsg.execute("LongStickDispenser"); + return true; +} + } // End of namespace Titanic |