diff options
Diffstat (limited to 'engines/sci')
-rw-r--r-- | engines/sci/engine/script.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/engines/sci/engine/script.cpp b/engines/sci/engine/script.cpp index 12d721ecc5..7cbb8cbac9 100644 --- a/engines/sci/engine/script.cpp +++ b/engines/sci/engine/script.cpp @@ -96,9 +96,23 @@ void script_adjust_opcode_formats(SciVersion version) { } } +#if 1 + #define FIND_SELECTOR(_slc_) _selectorMap._slc_ = findSelector(#_slc_) #define FIND_SELECTOR2(_slc_, _slcstr_) _selectorMap._slc_ = findSelector(_slcstr_) +#else + +// The defines below can be used to construct static selector tables for games which don't have +// a vocab.997 resource, by dumping the selector table from other similar versions or games +#define FIND_SELECTOR(_slc_) _selectorMap._slc_ = findSelector(#_slc_); \ + printf("\t{ \"%s\", %d },\n", #_slc_, _selectorMap._slc_) + +#define FIND_SELECTOR2(_slc_, _slcstr_) _selectorMap._slc_ = findSelector(_slcstr_); \ + printf("\t{ \"%s\", %d },\n", _slcstr_, _selectorMap._slc_) + +#endif + void Kernel::mapSelectors() { FIND_SELECTOR(init); FIND_SELECTOR(play); |