diff options
author | Paul Gilbert | 2016-08-18 22:45:58 -0400 |
---|---|---|
committer | Paul Gilbert | 2016-08-18 22:45:58 -0400 |
commit | dc91d30b76ded7ed7a648a0b0b43d8fe99c00cf6 (patch) | |
tree | 12e445180f88ffdd5f9ad0a200f1b9c39faa6180 /engines/titanic/game/credits_button.cpp | |
parent | df5f78037cc33fb63bdb5233a8ed378db77d9832 (diff) | |
download | scummvm-rg350-dc91d30b76ded7ed7a648a0b0b43d8fe99c00cf6.tar.gz scummvm-rg350-dc91d30b76ded7ed7a648a0b0b43d8fe99c00cf6.tar.bz2 scummvm-rg350-dc91d30b76ded7ed7a648a0b0b43d8fe99c00cf6.zip |
TITANIC: Implementing game classes
Diffstat (limited to 'engines/titanic/game/credits_button.cpp')
-rw-r--r-- | engines/titanic/game/credits_button.cpp | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/engines/titanic/game/credits_button.cpp b/engines/titanic/game/credits_button.cpp index 90bb1b5ebe..ee8f7bb329 100644 --- a/engines/titanic/game/credits_button.cpp +++ b/engines/titanic/game/credits_button.cpp @@ -24,6 +24,11 @@ namespace Titanic { +BEGIN_MESSAGE_MAP(CCreditsButton, CBackground) + ON_MESSAGE(MouseButtonUpMsg) + ON_MESSAGE(MouseButtonDownMsg) +END_MESSAGE_MAP() + CCreditsButton::CCreditsButton() : CBackground(), _fieldE0(1) { } @@ -39,4 +44,19 @@ void CCreditsButton::load(SimpleFile *file) { CBackground::load(file); } +bool CCreditsButton::MouseButtonUpMsg(CMouseButtonUpMsg *msg) { + return true; +} + +bool CCreditsButton::MouseButtonDownMsg(CMouseButtonDownMsg *msg) { + if (_fieldE0) { + playSound("a#20.wav"); + CSignalObject signalMsg; + signalMsg._numValue = 1; + signalMsg.execute("CreditsPlayer"); + } + + return true; +} + } // End of namespace Titanic |