diff options
author | Paul Gilbert | 2016-05-28 15:32:14 -0400 |
---|---|---|
committer | Paul Gilbert | 2016-07-15 19:16:22 -0400 |
commit | fb6e94e8bbe6e5fa2656f3a134b015cf4e986364 (patch) | |
tree | 54d92678fc271e571b89d47ae93b415767c95fda /engines | |
parent | a261041be74b42dd9877acd9968e53641fd62587 (diff) | |
download | scummvm-rg350-fb6e94e8bbe6e5fa2656f3a134b015cf4e986364.tar.gz scummvm-rg350-fb6e94e8bbe6e5fa2656f3a134b015cf4e986364.tar.bz2 scummvm-rg350-fb6e94e8bbe6e5fa2656f3a134b015cf4e986364.zip |
TITANIC: Remaining tag switch cases in TTparser considerRequests
Diffstat (limited to 'engines')
-rw-r--r-- | engines/titanic/true_talk/tt_parser.cpp | 63 | ||||
-rw-r--r-- | engines/titanic/true_talk/tt_parser.h | 2 |
2 files changed, 61 insertions, 4 deletions
diff --git a/engines/titanic/true_talk/tt_parser.cpp b/engines/titanic/true_talk/tt_parser.cpp index 664dcf7ced..91bc82db70 100644 --- a/engines/titanic/true_talk/tt_parser.cpp +++ b/engines/titanic/true_talk/tt_parser.cpp @@ -763,6 +763,7 @@ int TTparser::considerRequests(TTword *word) { break; case SEEK_ACTOR: + case MKTAG('S', 'A', 'C', 'T'): if (!_sentenceConcept->_concept0P) { flag = filterConcepts(5, 0); } else if (_sentenceConcept->_concept0P->compareTo("?") && @@ -1202,10 +1203,59 @@ int TTparser::considerRequests(TTword *word) { case MKTAG('L', 'O', 'C', 'F'): status = _sentenceConcept->createConcept(1, 5, word); - if (!status) { + if (!status) _sentenceConcept->_concept5P->_field20 = 2; - flag = true; + + flag = true; + break; + + case MKTAG('L', 'O', 'C', 'N'): + status = _sentenceConcept->createConcept(1, 5, word); + if (!status) + _sentenceConcept->_concept5P->_field20 = 1; + + flag = true; + break; + + case MKTAG('N', 'E', 'A', 'R'): + if (_conceptP->findBy20(0)) { + _conceptP->_field20 = 1; + } else { + TTpicture *newPictP = new TTpicture(TTstring("?"), WC_THING, 0, 0, 0, 0, 0); + status = addToConceptList(newPictP); + _conceptP->_field20 = 1; + if (!status) + delete newPictP; } + + flag = true; + break; + + case MKTAG('P', 'A', 'S', 'T'): + _sentenceConcept->_field18 = 1; + flag = true; + break; + + case MKTAG('P', 'L', 'E', 'Z'): + if (_sentence->_field58 < 10) + _sentence->_field58++; + break; + + case MKTAG('P', 'R', 'E', 'Z'): + _sentenceConcept->_field18 = 2; + flag = true; + break; + + case MKTAG('S', 'A', 'A', 'O'): + addNode(5); + addNode(4); + flag = true; + break; + + case MKTAG('S', 'S', 'T', 'A'): + addNode(13); + addNode(5); + flag = true; break; case MKTAG('T', 'E', 'A', 'C'): @@ -1215,7 +1265,13 @@ int TTparser::considerRequests(TTword *word) { flag = true; break; + case MKTAG('V', 'O', 'B', 'J'): + status = _sentenceConcept->createConcept(1, 2, word); + flag = true; + break; + default: + flag = true; break; } } @@ -1266,9 +1322,10 @@ int TTparser::processRequests(TTword *word) { return status; } -void TTparser::addToConceptList(TTword *word) { +int TTparser::addToConceptList(TTword *word) { TTconcept *concept = new TTconcept(word, ST_UNKNOWN_SCRIPT); addConcept(concept); + return 0; } void TTparser::addNode(uint tag) { diff --git a/engines/titanic/true_talk/tt_parser.h b/engines/titanic/true_talk/tt_parser.h index 7aa47fd12c..201de7eb0e 100644 --- a/engines/titanic/true_talk/tt_parser.h +++ b/engines/titanic/true_talk/tt_parser.h @@ -146,7 +146,7 @@ private: int considerRequests(TTword *word); int processRequests(TTword *word); - void addToConceptList(TTword *word); + int addToConceptList(TTword *word); int checkReferent(TTpronoun *pronoun); /** |