diff options
Diffstat (limited to 'engines/titanic/true_talk/tt_npc_script.h')
-rw-r--r-- | engines/titanic/true_talk/tt_npc_script.h | 37 |
1 files changed, 35 insertions, 2 deletions
diff --git a/engines/titanic/true_talk/tt_npc_script.h b/engines/titanic/true_talk/tt_npc_script.h index 66cb3af1c3..3a4ac570b7 100644 --- a/engines/titanic/true_talk/tt_npc_script.h +++ b/engines/titanic/true_talk/tt_npc_script.h @@ -37,7 +37,6 @@ class CPetControl; class TTroomScript; class TTsentence; struct TTsentenceEntry; -class TTsentenceEntries; struct TTnpcScriptResponse { uint _tag; @@ -62,6 +61,40 @@ struct TTscriptRange { bool isSequential); }; + +struct TTsentenceEntry { + int _field0; + int _field4; + CString _string8; + int _fieldC; + CString _string10; + CString _string14; + CString _string18; + CString _string1C; + int _field20; + CString _string24; + int _field28; + int _field2C; + int _field30; + + TTsentenceEntry() : _field0(0), _field4(0), _fieldC(0), + _field20(0), _field28(0), _field2C(0), _field30(0) {} + + /** + * Load an entry from the passed stream, and returns true + * if an entry was successfully loaded + */ + bool load(Common::SeekableReadStream *s); +}; + +class TTsentenceEntries : public Common::Array<TTsentenceEntry> { +public: + /** + * Load a list of entries from the specified resource + */ + void load(const CString &resName); +}; + struct TTscriptMapping { uint _id; uint _values[8]; @@ -115,7 +148,7 @@ protected: int _valuesPerResponse; Common::Array<TTscriptRange> _ranges; TTscriptMappings _mappings; - const TTsentenceEntries *_entriesP; + TTsentenceEntries _entries; int _entryCount; int _field68; int _field6C; |