diff options
author | Max Horn | 2009-05-26 14:44:14 +0000 |
---|---|---|
committer | Max Horn | 2009-05-26 14:44:14 +0000 |
commit | c96cf97ea7e7651c4b2e247d2a111fc4b538d50d (patch) | |
tree | 3e7797d97b11b26d1133900a2dc584258ef0a9f0 /engines/sci/vocabulary.h | |
parent | 1e2c539e42448acb96b67b0fceee0d537afac757 (diff) | |
download | scummvm-rg350-c96cf97ea7e7651c4b2e247d2a111fc4b538d50d.tar.gz scummvm-rg350-c96cf97ea7e7651c4b2e247d2a111fc4b538d50d.tar.bz2 scummvm-rg350-c96cf97ea7e7651c4b2e247d2a111fc4b538d50d.zip |
SCI: Merged vocab_debug.cpp into vocabulary.cpp; cleanup
svn-id: r40915
Diffstat (limited to 'engines/sci/vocabulary.h')
-rw-r--r-- | engines/sci/vocabulary.h | 44 |
1 files changed, 20 insertions, 24 deletions
diff --git a/engines/sci/vocabulary.h b/engines/sci/vocabulary.h index 575e18fc8c..9276a399d6 100644 --- a/engines/sci/vocabulary.h +++ b/engines/sci/vocabulary.h @@ -39,11 +39,11 @@ class ResourceManager; /*#define VOCABULARY_DEBUG */ +/** The string used to identify the "unknown" SCI0 function for each game */ #define SCRIPT_UNKNOWN_FUNCTION_STRING "[Unknown]" -/* The string used to identify the "unknown" SCI0 function for each game */ +/** Number of bytes allocated on the heap to store bad words if parsing fails */ #define PARSE_HEAP_SIZE 64 -/* Number of bytes allocated on the heap to store bad words if parsing fails */ struct opcode { @@ -52,17 +52,22 @@ struct opcode { Common::String name; }; -#define VOCAB_RESOURCE_OPCODES 998 -#define VOCAB_RESOURCE_KNAMES 999 - -#define VOCAB_RESOURCE_SCI0_MAIN_VOCAB 0 -#define VOCAB_RESOURCE_SCI0_PARSE_TREE_BRANCHES 900 -#define VOCAB_RESOURCE_SCI0_SUFFIX_VOCAB 901 +enum { + VOCAB_RESOURCE_CLASSES = 996, + VOCAB_RESOURCE_SNAMES = 997, + VOCAB_RESOURCE_OPCODES = 998, + VOCAB_RESOURCE_KNAMES = 999, + + VOCAB_RESOURCE_SCI0_MAIN_VOCAB = 0, + VOCAB_RESOURCE_SCI0_PARSE_TREE_BRANCHES = 900, + VOCAB_RESOURCE_SCI0_SUFFIX_VOCAB = 901, + + VOCAB_RESOURCE_SCI1_MAIN_VOCAB = 900, + VOCAB_RESOURCE_SCI1_PARSE_TREE_BRANCHES = 901, + VOCAB_RESOURCE_SCI1_SUFFIX_VOCAB = 902, + VOCAB_RESOURCE_SCI1_CHAR_TRANSFORMS = 913 +}; -#define VOCAB_RESOURCE_SCI1_MAIN_VOCAB 900 -#define VOCAB_RESOURCE_SCI1_PARSE_TREE_BRANCHES 901 -#define VOCAB_RESOURCE_SCI1_SUFFIX_VOCAB 902 -#define VOCAB_RESOURCE_SCI1_CHAR_TRANSFORMS 913 enum { VOCAB_CLASS_PREPOSITION = 0x01, @@ -76,8 +81,6 @@ enum { VOCAB_CLASS_NUMBER = 0x001 }; -extern const char *class_names[]; /* Vocabulary class names */ - #define VOCAB_CLASS_ANYWORD 0xff /* Anywords are ignored by the parser */ @@ -181,23 +184,16 @@ struct parse_tree_node_t { -/*FIXME: These need freeing functions...*/ - -#if 0 -int *vocabulary_get_classes(ResourceManager *resmgr, int *count); -int vocabulary_get_class_count(ResourceManager *resmgr); -#endif - /** * Fills the given StringList with selector names. * Returns true upon success, false oterwise. */ -bool vocabulary_get_snames(ResourceManager *resmgr, bool isOldSci0, Common::StringList &selectorNames); +bool vocab_get_snames(ResourceManager *resmgr, bool isOldSci0, Common::StringList &selectorNames); /** * Obtain the list of opcodes. */ -void vocabulary_get_opcodes(ResourceManager *resmgr, Common::Array<opcode> &opcodes); +void vocab_get_opcodes(ResourceManager *resmgr, Common::Array<opcode> &opcodes); /** * Fills a StringList with kernel function names. @@ -207,7 +203,7 @@ void vocabulary_get_opcodes(ResourceManager *resmgr, Common::Array<opcode> &opco * The resulting list has the same format regardless of the format of the * name table of the resource (the format changed between version 0 and 1). */ -void vocabulary_get_knames(ResourceManager *resmgr, Common::StringList &names); +void vocab_get_knames(ResourceManager *resmgr, Common::StringList &names); /** |