aboutsummaryrefslogtreecommitdiff
path: root/engines/titanic/true_talk
diff options
context:
space:
mode:
Diffstat (limited to 'engines/titanic/true_talk')
-rw-r--r--engines/titanic/true_talk/doorbot_script.cpp5
-rw-r--r--engines/titanic/true_talk/doorbot_script.h1
2 files changed, 6 insertions, 0 deletions
diff --git a/engines/titanic/true_talk/doorbot_script.cpp b/engines/titanic/true_talk/doorbot_script.cpp
index ab50eca0c6..ac0b1aff21 100644
--- a/engines/titanic/true_talk/doorbot_script.cpp
+++ b/engines/titanic/true_talk/doorbot_script.cpp
@@ -61,6 +61,11 @@ DoorbotScript::DoorbotScript(int val1, const char *charClass, int v2,
_states.load("States/Doorbot");
}
+DoorbotScript::~DoorbotScript() {
+ for (int idx = 0; idx < 11; ++idx)
+ _sentences[idx].clear();
+}
+
void DoorbotScript::setupSentences() {
for (int idx = 35; idx < 40; ++idx)
CTrueTalkManager::setFlags(idx, 0);
diff --git a/engines/titanic/true_talk/doorbot_script.h b/engines/titanic/true_talk/doorbot_script.h
index 78ebcbfd68..536e9d42ca 100644
--- a/engines/titanic/true_talk/doorbot_script.h
+++ b/engines/titanic/true_talk/doorbot_script.h
@@ -58,6 +58,7 @@ private:
public:
DoorbotScript(int val1, const char *charClass, int v2,
const char *charName, int v3, int val2, int v4, int v5, int v6, int v7);
+ virtual ~DoorbotScript();
/**
* Chooses and adds a conversation response based on a specified tag Id.