diff options
author | Filippos Karapetis | 2009-08-31 21:50:14 +0000 |
---|---|---|
committer | Filippos Karapetis | 2009-08-31 21:50:14 +0000 |
commit | fed9e3e2df083ac86d513d7ba3b08bfca76a272b (patch) | |
tree | eee9722f773b65386a7d9a9568ba5662e07ce955 /engines/sci/engine | |
parent | fa9ce61a5d982c8c91f7cd50c15775c06101a94c (diff) | |
download | scummvm-rg350-fed9e3e2df083ac86d513d7ba3b08bfca76a272b.tar.gz scummvm-rg350-fed9e3e2df083ac86d513d7ba3b08bfca76a272b.tar.bz2 scummvm-rg350-fed9e3e2df083ac86d513d7ba3b08bfca76a272b.zip |
Cleanup
svn-id: r43869
Diffstat (limited to 'engines/sci/engine')
-rw-r--r-- | engines/sci/engine/static_selectors.cpp | 23 |
1 files changed, 8 insertions, 15 deletions
diff --git a/engines/sci/engine/static_selectors.cpp b/engines/sci/engine/static_selectors.cpp index 532c750032..1ff5dd8c2e 100644 --- a/engines/sci/engine/static_selectors.cpp +++ b/engines/sci/engine/static_selectors.cpp @@ -90,10 +90,6 @@ static const SelectorRemap sci11SelectorRemap[] = { { "syncTime", 279 }, { "syncCue", 280 } }; -// A macro for loading one of the above tables in the function below -#define USE_SELECTOR_TABLE(x) \ - - Common::StringList Kernel::checkStaticSelectorNames(SciVersion version) { Common::StringList names; int offset = (version < SCI_VERSION_1_1) ? 3 : 0; @@ -108,7 +104,9 @@ Common::StringList Kernel::checkStaticSelectorNames(SciVersion version) { for (i = offset; i < count; i++) names[i] = sci0Selectors[i - offset]; - if (version >= SCI_VERSION_1_EGA) { + if (version <= SCI_VERSION_01) { + selectorRemap = sci0SelectorRemap; + } else { int count2 = ARRAYSIZE(sci1Selectors); names[handleIndex + offset] = "nodePtr"; names[canBeHereIndex + offset] = "cantBeHere"; @@ -116,19 +114,14 @@ Common::StringList Kernel::checkStaticSelectorNames(SciVersion version) { for (i = count; i < count + count2; i++) names[i] = sci1Selectors[i - count]; - } - if (version <= SCI_VERSION_01) - selectorRemap = sci0SelectorRemap; - else if (version >= SCI_VERSION_1_EGA && version <= SCI_VERSION_1_LATE) - selectorRemap = sci1SelectorRemap; - else - selectorRemap = sci11SelectorRemap; + selectorRemap = (version < SCI_VERSION_1_1) ? sci1SelectorRemap : sci11SelectorRemap; + } for (uint32 k = 0; k < ARRAYSIZE(selectorRemap); k++) { - if (selectorRemap[k].slot >= names.size()) \ - names.resize(selectorRemap[k].slot + 1); \ - names[selectorRemap[k].slot] = selectorRemap[k].name; \ + if (selectorRemap[k].slot >= names.size()) + names.resize(selectorRemap[k].slot + 1); + names[selectorRemap[k].slot] = selectorRemap[k].name; } return names; |