ScummVM API documentation
script_handler.h
1/* ScummVM - Graphic Adventure Engine
2 *
3 * ScummVM is the legal property of its developers, whose names
4 * are too numerous to list here. Please refer to the COPYRIGHT
5 * file distributed with this source distribution.
6 *
7 * This program is free software: you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation, either version 3 of the License, or
10 * (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program. If not, see <http://www.gnu.org/licenses/>.
19 *
20 */
21
22#ifndef TITANIC_SCRIPT_HANDLER_H
23#define TITANIC_SCRIPT_HANDLER_H
24
25#include "titanic/true_talk/tt_npc_script.h"
26#include "titanic/true_talk/tt_parser.h"
27#include "titanic/true_talk/tt_room_script.h"
28#include "titanic/true_talk/tt_string.h"
29#include "titanic/true_talk/tt_vocab.h"
30#include "titanic/support/exe_resources.h"
31
32namespace Titanic {
33
34class CTitleEngine;
35
37private:
38 CTitleEngine *_owner;
39 int _inputCtr;
40private:
41 void handleWord1(const TTstring *str);
42 void handleWord2(const TTstring *str);
43public:
44 TTparser _parser;
45 TTvocab *_vocab;
46 TTscriptBase *_script;
47 TTconcept *_concept1P;
48 TTconcept *_concept2P;
49 TTconcept *_concept3P;
50 TTconcept *_concept4P;
51public:
52 CScriptHandler(CTitleEngine *owner, int val1, VocabMode vocabMode);
54
58 ScriptChangedResult scriptChanged(TTroomScript *roomScript,
59 TTnpcScript *npcScript, uint dialogueId);
60
61 int processInput(TTroomScript *roomScript, TTnpcScript *npcScript,
62 const TTstring &line);
63
68
72 void setParserConcept(TTconcept *newConcept, TTconcept *oldConcept);
73
77 int setResponse(TTscriptBase *script, TTresponse *response);
78
79 void handleWord(const TTstring *str);
80};
81
82} // End of namespace Titanic
83
84#endif /* TITANIC_SCRIPT_HANDLER_H */
Definition: script_handler.h:36
void setParserConcept(TTconcept *newConcept, TTconcept *oldConcept)
int setResponse(TTscriptBase *script, TTresponse *response)
SimpleFile * openResource(const CString &name)
ScriptChangedResult scriptChanged(TTroomScript *roomScript, TTnpcScript *npcScript, uint dialogueId)
Definition: string.h:40
Definition: title_engine.h:41
Definition: simple_file.h:49
Definition: tt_concept.h:35
Definition: tt_npc_script.h:88
Definition: tt_parser.h:66
Definition: tt_response.h:30
Definition: tt_room_script.h:61
Definition: tt_script_base.h:38
Definition: tt_string.h:45
Definition: tt_vocab.h:32