diff options
author | Paul Gilbert | 2016-07-24 23:29:59 -0400 |
---|---|---|
committer | Paul Gilbert | 2016-07-24 23:29:59 -0400 |
commit | 2844574dc0f9e8c50e13cbebddd68db8c4dbc0bf (patch) | |
tree | e7d1a5a5bd3476ee7a3d458b356053cf01f9e470 /engines/titanic | |
parent | 539f13f5a4238a091dc4ff6bf1ddbe0bf2e201e3 (diff) | |
download | scummvm-rg350-2844574dc0f9e8c50e13cbebddd68db8c4dbc0bf.tar.gz scummvm-rg350-2844574dc0f9e8c50e13cbebddd68db8c4dbc0bf.tar.bz2 scummvm-rg350-2844574dc0f9e8c50e13cbebddd68db8c4dbc0bf.zip |
TITANIC: Added NPC Script setDialRegion methods
Diffstat (limited to 'engines/titanic')
-rw-r--r-- | engines/titanic/true_talk/barbot_script.cpp | 7 | ||||
-rw-r--r-- | engines/titanic/true_talk/barbot_script.h | 7 | ||||
-rw-r--r-- | engines/titanic/true_talk/doorbot_script.cpp | 10 | ||||
-rw-r--r-- | engines/titanic/true_talk/doorbot_script.h | 7 | ||||
-rw-r--r-- | engines/titanic/true_talk/liftbot_script.cpp | 6 | ||||
-rw-r--r-- | engines/titanic/true_talk/liftbot_script.h | 6 |
6 files changed, 33 insertions, 10 deletions
diff --git a/engines/titanic/true_talk/barbot_script.cpp b/engines/titanic/true_talk/barbot_script.cpp index 080b48aea3..36916e2710 100644 --- a/engines/titanic/true_talk/barbot_script.cpp +++ b/engines/titanic/true_talk/barbot_script.cpp @@ -869,12 +869,13 @@ int BarbotScript::proc25(int val1, int val2, TTroomScript *roomScript, TTsentenc void BarbotScript::proc26(int v1, const TTsentenceEntry *entry, TTroomScript *roomScript, TTsentence *sentence) { } -void BarbotScript::proc32() { - warning("TODO"); +void BarbotScript::setDialRegion(int dialNum, int region) { + TTnpcScript::setDialRegion(dialNum, region); + selectResponse(250365); + applyResponse(); } int BarbotScript::proc36(int tagId) const { - warning("TODO"); return 0; } diff --git a/engines/titanic/true_talk/barbot_script.h b/engines/titanic/true_talk/barbot_script.h index a5e6b50dc3..cc8c2f19e3 100644 --- a/engines/titanic/true_talk/barbot_script.h +++ b/engines/titanic/true_talk/barbot_script.h @@ -73,7 +73,12 @@ public: virtual int proc23() const; virtual int proc25(int val1, int val2, TTroomScript *roomScript, TTsentence *sentence) const; virtual void proc26(int v1, const TTsentenceEntry *entry, TTroomScript *roomScript, TTsentence *sentence); - virtual void proc32(); + + /** + * Sets a given dial to be pointing in a specified region (0 to 2) + */ + virtual void setDialRegion(int dialNum, int region); + virtual int proc36(int val) const; }; diff --git a/engines/titanic/true_talk/doorbot_script.cpp b/engines/titanic/true_talk/doorbot_script.cpp index 51647b98e0..15ede3a727 100644 --- a/engines/titanic/true_talk/doorbot_script.cpp +++ b/engines/titanic/true_talk/doorbot_script.cpp @@ -148,8 +148,14 @@ int DoorbotScript::proc25(int val1, int val2, TTroomScript *roomScript, TTsenten void DoorbotScript::proc26(int v1, const TTsentenceEntry *entry, TTroomScript *roomScript, TTsentence *sentence) { } -void DoorbotScript::proc32() { - warning("TODO"); +void DoorbotScript::setDialRegion(int dialNum, int region) { + TTnpcScript::setDialRegion(dialNum, region); + if (dialNum == 1 && region != 1) { + CTrueTalkManager::setFlags(37, dialNum); + } else { + addResponse(getDialogueId(221777)); + applyResponse(); + } } int DoorbotScript::proc36(int id) const { diff --git a/engines/titanic/true_talk/doorbot_script.h b/engines/titanic/true_talk/doorbot_script.h index 16f5c9684b..21a3e7f976 100644 --- a/engines/titanic/true_talk/doorbot_script.h +++ b/engines/titanic/true_talk/doorbot_script.h @@ -67,7 +67,12 @@ public: virtual int proc23() const; virtual int proc25(int val1, int val2, TTroomScript *roomScript, TTsentence *sentence) const; virtual void proc26(int v1, const TTsentenceEntry *entry, TTroomScript *roomScript, TTsentence *sentence); - virtual void proc32(); + + /** + * Sets a given dial to be pointing in a specified region (0 to 2) + */ + virtual void setDialRegion(int dialNum, int region); + virtual int proc36(int val) const; }; diff --git a/engines/titanic/true_talk/liftbot_script.cpp b/engines/titanic/true_talk/liftbot_script.cpp index 826690be5a..cfa8a70480 100644 --- a/engines/titanic/true_talk/liftbot_script.cpp +++ b/engines/titanic/true_talk/liftbot_script.cpp @@ -125,8 +125,10 @@ int LiftbotScript::proc25(int val1, int val2, TTroomScript *roomScript, TTsenten void LiftbotScript::proc26(int v1, const TTsentenceEntry *entry, TTroomScript *roomScript, TTsentence *sentence) { } -void LiftbotScript::proc32() { - warning("TODO"); +void LiftbotScript::setDialRegion(int dialNum, int region) { + TTnpcScript::setDialRegion(dialNum, region); + addResponse(getDialogueId(210688)); + applyResponse(); } } // End of namespace Titanic diff --git a/engines/titanic/true_talk/liftbot_script.h b/engines/titanic/true_talk/liftbot_script.h index 20c9444b11..553c3712ad 100644 --- a/engines/titanic/true_talk/liftbot_script.h +++ b/engines/titanic/true_talk/liftbot_script.h @@ -64,7 +64,11 @@ public: virtual int proc23() const; virtual int proc25(int val1, int val2, TTroomScript *roomScript, TTsentence *sentence) const; virtual void proc26(int v1, const TTsentenceEntry *entry, TTroomScript *roomScript, TTsentence *sentence); - virtual void proc32(); + + /** + * Sets a given dial to be pointing in a specified region (0 to 2) + */ + virtual void setDialRegion(int dialNum, int region); }; } // End of namespace Titanic |