diff options
author | Max Horn | 2009-09-17 14:54:11 +0000 |
---|---|---|
committer | Max Horn | 2009-09-17 14:54:11 +0000 |
commit | c38f150d56e40ddc6a8c04aae72f7be8e2914a76 (patch) | |
tree | 6a62e5ee0d988ee6c3474aa650c60495f69a2292 /engines/sci | |
parent | e3e1c0754f09753ce3a35b0dd6bbd52734a195ec (diff) | |
download | scummvm-rg350-c38f150d56e40ddc6a8c04aae72f7be8e2914a76.tar.gz scummvm-rg350-c38f150d56e40ddc6a8c04aae72f7be8e2914a76.tar.bz2 scummvm-rg350-c38f150d56e40ddc6a8c04aae72f7be8e2914a76.zip |
SCI: Moved Kernel::findSelector from vocabulary.cpp to engine/kernel.cpp
svn-id: r44161
Diffstat (limited to 'engines/sci')
-rw-r--r-- | engines/sci/engine/kernel.cpp | 11 | ||||
-rw-r--r-- | engines/sci/vocabulary.cpp | 11 |
2 files changed, 11 insertions, 11 deletions
diff --git a/engines/sci/engine/kernel.cpp b/engines/sci/engine/kernel.cpp index 812b12a456..eb3abec50d 100644 --- a/engines/sci/engine/kernel.cpp +++ b/engines/sci/engine/kernel.cpp @@ -415,6 +415,17 @@ void Kernel::detectSciFeatures() { printf("new\n"); } +int Kernel::findSelector(const char *selectorName) const { + for (uint pos = 0; pos < _selectorNames.size(); ++pos) { + if (_selectorNames[pos] == selectorName) + return pos; + } + + debugC(2, kDebugLevelVM, "Could not map '%s' to any selector\n", selectorName); + + return -1; +} + void Kernel::loadSelectorNames() { Resource *r = _resMan->findResource(ResourceId(kResourceTypeVocab, VOCAB_RESOURCE_SELECTORS), 0); bool oldScriptHeader = (_resMan->sciVersion() == SCI_VERSION_0_EARLY); diff --git a/engines/sci/vocabulary.cpp b/engines/sci/vocabulary.cpp index 1909335904..60e3334af0 100644 --- a/engines/sci/vocabulary.cpp +++ b/engines/sci/vocabulary.cpp @@ -467,17 +467,6 @@ void Vocabulary::printParserWords() const { con->DebugPrintf("\n"); } -int Kernel::findSelector(const char *selectorName) const { - for (uint pos = 0; pos < _selectorNames.size(); ++pos) { - if (_selectorNames[pos] == selectorName) - return pos; - } - - debugC(2, kDebugLevelVM, "Could not map '%s' to any selector\n", selectorName); - - return -1; -} - void _vocab_recursive_ptree_dump_treelike(parse_tree_node_t *nodes, int nr, int prevnr) { if ((nr > VOCAB_TREE_NODES)/* || (nr < prevnr)*/) { printf("Error(%04x)", nr); |