diff options
author | Filippos Karapetis | 2009-05-14 12:38:50 +0000 |
---|---|---|
committer | Filippos Karapetis | 2009-05-14 12:38:50 +0000 |
commit | f75c95045732f8562ce1f231417c345db43e50c4 (patch) | |
tree | acbcc57f44943ca9aaad7e4b5d1e94415449a79d | |
parent | e03fba03b5362df7133b77ceebe7f86d9fd39caf (diff) | |
download | scummvm-rg350-f75c95045732f8562ce1f231417c345db43e50c4.tar.gz scummvm-rg350-f75c95045732f8562ce1f231417c345db43e50c4.tar.bz2 scummvm-rg350-f75c95045732f8562ce1f231417c345db43e50c4.zip |
- Replaced SCI_VERSION_FTU_LOFS_ABSOLUTE with the GF_SCI1_LOFSABSOLUTE game flag
- Moved the version defines outside of versions.h
svn-id: r40559
-rw-r--r-- | engines/sci/console.cpp | 1 | ||||
-rw-r--r-- | engines/sci/detection.cpp | 102 | ||||
-rw-r--r-- | engines/sci/engine/game.cpp | 5 | ||||
-rw-r--r-- | engines/sci/engine/kmovement.cpp | 1 | ||||
-rw-r--r-- | engines/sci/engine/kscripts.cpp | 1 | ||||
-rw-r--r-- | engines/sci/engine/ksound.cpp | 2 | ||||
-rw-r--r-- | engines/sci/engine/savegame.h | 2 | ||||
-rw-r--r-- | engines/sci/engine/state.h | 2 | ||||
-rw-r--r-- | engines/sci/engine/vm.cpp | 10 | ||||
-rw-r--r-- | engines/sci/engine/vm.h | 3 | ||||
-rw-r--r-- | engines/sci/exereader.cpp | 2 | ||||
-rw-r--r-- | engines/sci/sci.h | 17 | ||||
-rw-r--r-- | engines/sci/scicore/versions.h | 18 | ||||
-rw-r--r-- | engines/sci/scicore/vocabulary.h | 2 |
14 files changed, 83 insertions, 85 deletions
diff --git a/engines/sci/console.cpp b/engines/sci/console.cpp index 2a2092d861..8dc95439ba 100644 --- a/engines/sci/console.cpp +++ b/engines/sci/console.cpp @@ -28,7 +28,6 @@ #include "sci/sci.h" #include "sci/console.h" #include "sci/scicore/resource.h" -#include "sci/scicore/versions.h" #include "sci/scicore/vocabulary.h" namespace Sci { diff --git a/engines/sci/detection.cpp b/engines/sci/detection.cpp index 2973a1c5c9..f6b467937f 100644 --- a/engines/sci/detection.cpp +++ b/engines/sci/detection.cpp @@ -28,7 +28,6 @@ #include "sci/sci.h" #include "sci/exereader.h" -#include "sci/scicore/versions.h" namespace Sci { @@ -37,6 +36,9 @@ namespace Sci { #define GF_FOR_SCI0_BEFORE_502 (GF_SCI0_OLDGFXFUNCS | GF_SCI0_OLDGETTIME) #define GF_FOR_SCI0_BEFORE_629 GF_SCI0_OLDGETTIME +// SCI1 +#define GF_FOR_SCI1_200_OR_LATER GF_SCI1_LOFSABSOLUTE + // Titles of the games static const PlainGameDescriptor SciGameTitles[] = { {"sci", "Sierra SCI Game"}, @@ -140,7 +142,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.002", 0, "d226d7d3b4f77c4a566913fc310487fc", 792380}, {"resource.003", 0, "d226d7d3b4f77c4a566913fc310487fc", 464348}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformAmiga, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -154,7 +156,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.002", 0, "85e51acb5f9c539d66e3c8fe40e17da5", 826309}, {"resource.003", 0, "85e51acb5f9c539d66e3c8fe40e17da5", 493638}, {NULL, 0, NULL, 0}}, Common::DE_DEU, Common::kPlatformAmiga, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -178,7 +180,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.001", 0, "d2f5a1be74ed963fa849a76892be5290", 794832}, {"resource.002", 0, "c0c29c51af66d65cb53f49e785a2d978", 1280907}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 0, 510) }, @@ -190,7 +192,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.000", 0, "27ec5fa09cd12a7fd16e86d96a2ed245", 1197694}, {"resource.001", 0, "735be4e58957180cfc807d5e18fdffcd", 1433302}, {NULL, 0, NULL, 0}}, Common::ES_ESP, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -350,7 +352,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.005", 0, "1c3804e56b114028c5873a35c2f06d13", 653002}, {"resource.006", 0, "f9487732289a4f4966b4e34eea413325", 842817}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformAmiga, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -366,7 +368,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.005", 0, "d036df0872f2db19bca34601276be2d7", 1154950}, {"resource.006", 0, "b367a6a59f29ee30dde1d88a5a41152d", 1042966}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -382,7 +384,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.004", 0, "9cfce07e204a329e94fda8b5657621da", 1261462}, {"resource.005", 0, "21ebe6b39b57a73fc449f67f013765aa", 1284720}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -397,7 +399,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.004", 0, "9cfce07e204a329e94fda8b5657621da", 1260237}, {"resource.005", 0, "21ebe6b39b57a73fc449f67f013765aa", 1284609}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -423,7 +425,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.005", 0, "d036df0872f2db19bca34601276be2d7", 1176914}, {"resource.006", 0, "b367a6a59f29ee30dde1d88a5a41152d", 1123585}, {NULL, 0, NULL, 0}}, Common::DE_DEU, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -457,7 +459,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.002", 0, "28fe9b4f0567e71feb198bc9f3a2c605", 1241816}, {"resource.003", 0, "f3146df0ad4297f5ce35aa8c4753bf6c", 586832}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - GF_SCI1_NEWSETCURSOR, + GF_FOR_SCI1_200_OR_LATER | GF_SCI1_NEWSETCURSOR, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 0, 510) }, @@ -470,7 +472,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.002", 0, "323b3b12f43d53f27d259beb225f0aa7", 1129316}, {"resource.003", 0, "83ac03e4bddb2c1ac2d36d2a587d0536", 1145616}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - GF_SCI1_NEWSETCURSOR, + GF_FOR_SCI1_200_OR_LATER | GF_SCI1_NEWSETCURSOR, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 0, 510) }, @@ -483,7 +485,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.002", 0, "02d7d0411f7903aacb3bc8b0f8ca8a9a", 1202581}, {"resource.003", 0, "84dd11b6825255671c703aee5ceff620", 1175835}, {NULL, 0, NULL, 0}}, Common::DE_DEU, Common::kPlatformPC, 0}, - GF_SCI1_NEWSETCURSOR, + GF_FOR_SCI1_200_OR_LATER | GF_SCI1_NEWSETCURSOR, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 0, 510) }, @@ -497,7 +499,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.002", 0, "2d21a1d2dcbffa551552e3e0725d2284", 1186033}, {"resource.003", 0, "84dd11b6825255671c703aee5ceff620", 1174993}, {NULL, 0, NULL, 0}}, Common::ES_ESP, Common::kPlatformPC, 0}, - GF_SCI1_NEWSETCURSOR, + GF_FOR_SCI1_200_OR_LATER | GF_SCI1_NEWSETCURSOR, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 0, 510) }, @@ -773,7 +775,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.000", 0, "595b6039ea1356e7f96a52c58eedcf22", 355791}, {"resource.001", 0, "143df8aef214a2db34c2d48190742012", 632273}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformAmiga, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -786,7 +788,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.000", 0, "6ef28cac094dcd97fdb461662ead6f92", 541845}, {"resource.001", 0, "0a98a268ee99b92c233a0d7187c1f0fa", 845795}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) // this is just a guess }, @@ -963,7 +965,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.000", 0, "449471bfd77be52f18a3773c7f7d843d", 571368}, {"resource.001", 0, "b45a581ff8751e052c7e364f58d3617f", 16800210}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - GF_SCI1_NEWSETCURSOR, + GF_FOR_SCI1_200_OR_LATER | GF_SCI1_NEWSETCURSOR, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 784) }, @@ -981,7 +983,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.007", 0, "2f48faf27666b58c276dda20f91f4a93", 1240456}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, 0, - SCI_VERSION_AUTODETECT, + 0, SCI_VERSION(1, 000, 60) }, @@ -1305,7 +1307,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.002", 0, "5790ac0505f7ca98d4567132b875eb1e", 681041}, {"resource.003", 0, "4a34c3367c2fe7eb380d741374da1989", 572251}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformAmiga, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 784) }, @@ -1318,7 +1320,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.001", 0, "ec20246209d7b19f38989261e5c8f5b8", 1111226}, {"resource.002", 0, "85d6935ef77e6b0e16bc307640a0d913", 1088312}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 577) }, @@ -1330,7 +1332,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.001", 0, "d34cadb11e1aefbb497cf91bc1d3baa7", 1114688}, {"resource.002", 0, "85b030bb66d5342b0a068f1208c431a8", 1078443}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -1355,7 +1357,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.002", 0, "3fe2a3aec0ed53c7d6db1845a67e3aa2", 1095908}, {"resource.003", 0, "ac175df0ea9a2cba57f0248651856d27", 376556}, {NULL, 0, NULL, 0}}, Common::ES_ESP, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -1512,7 +1514,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.005", 0, "f8b2d1137bb767e5d232056b99dd69eb", 623621}, {"resource.006", 0, "bafc64e3144f115dc58c6aee02de98fb", 715598}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformAmiga, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 784) }, @@ -1530,7 +1532,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.006", 0, "bafc64e3144f115dc58c6aee02de98fb", 754966}, {"resource.007", 0, "59eba83ad465b08d763b44f86afa86f6", 683135}, {NULL, 0, NULL, 0}}, Common::DE_DEU, Common::kPlatformAmiga, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 784) }, @@ -1557,7 +1559,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.006", 0, "dda27ce00682aa76198dac124bbbe334", 1024810}, {"resource.007", 0, "ac443fae1285fb359bf2b2bc6a7301ae", 1030656}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -1574,7 +1576,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.006", 0, "dda27ce00682aa76198dac124bbbe334", 1021774}, {"resource.007", 0, "ac443fae1285fb359bf2b2bc6a7301ae", 993408}, {NULL, 0, NULL, 0}}, Common::DE_DEU, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) // placed the English version here }, @@ -1592,7 +1594,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.006", 0, "dda27ce00682aa76198dac124bbbe334", 946540}, {"resource.007", 0, "ac443fae1285fb359bf2b2bc6a7301ae", 958842}, {NULL, 0, NULL, 0}}, Common::FR_FRA, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -1610,7 +1612,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.006", 0, "dda27ce00682aa76198dac124bbbe334", 1015136}, {"resource.007", 0, "ac443fae1285fb359bf2b2bc6a7301ae", 987222}, {NULL, 0, NULL, 0}}, Common::ES_ESP, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -1621,7 +1623,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.map", 0, "a99776df795127f387cb35dae872d4e4", 5919}, {"resource.000", 0, "a8989a5a89e7d4f702b26b378c7a357a", 7001981}, {NULL, 0, NULL, 0}}, Common::IT_ITA, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -1908,7 +1910,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.map", 0, "5b457cbe5042f557e5b610148171f6c0", 1158}, {"resource.001", 0, "453ea81ef66a50cbe33ce06302afe47f", 229737}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 679) }, @@ -2031,7 +2033,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.003", 0, "630bfa65beb05f743552704ac2899dae", 759891}, {"resource.004", 0, "7b229fbdf30d670d0728cede3e984a7e", 838663}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformAmiga, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 784) }, @@ -2047,7 +2049,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.004", 0, "6258d5dd85898d8e218eb8113ebc9059", 722738}, {"resource.005", 0, "6258d5dd85898d8e218eb8113ebc9059", 704485}, {NULL, 0, NULL, 0}}, Common::DE_DEU, Common::kPlatformAmiga, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 784) }, @@ -2062,7 +2064,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.003", 0, "8791b9eef53edf77c2dac950142221d3", 1159791}, {"resource.004", 0, "1b91e891a3c60a941dac0eecdf83375b", 1143606}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -2074,7 +2076,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.000", 0, "277f97771f7a6d89677141f02da313d6", 65150}, {"resource.001", 0, "5c5a551b6c86cce2ee75becb90e0b586", 624411}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, ADGF_DEMO}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 0, 510) }, @@ -2089,7 +2091,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.003", 0, "4836f460f4cfc8de61e2df4c45775504", 1180956}, {"resource.004", 0, "0c3eb84b9755852d9e795e0d5c9373c7", 1171760}, {NULL, 0, NULL, 0}}, Common::DE_DEU, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -2480,7 +2482,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.004", 0, "b25a1539c71701f7715f738c5037e9a6", 775515}, {"resource.005", 0, "640ffe1a9acde392cc33cc1b1a528328", 806324}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformAmiga, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) // TODO: best bet, exe seems packed }, @@ -2495,7 +2497,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.003", 0, "c47600e50c6fc591957ae0c5020ee7b8", 1213262}, {"resource.004", 0, "e19ea4ad131472f9238590f2e1d40289", 1203051}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -2521,7 +2523,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.004", 0, "9b78228ad4f9f335fedf74f1812dcfca", 513325}, {"resource.005", 0, "7d4ebcb745c0bf8fc42e4013f52ecd49", 1101812}, {NULL, 0, NULL, 0}}, Common::ES_ESP, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 510) }, @@ -2549,7 +2551,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.004", 0, "6d8f34090503ce937e7dbef6cb6cdb6a", 545053}, {"resource.005", 0, "6d8f34090503ce937e7dbef6cb6cdb6a", 687507}, {NULL, 0, NULL, 0}}, Common::DE_DEU, Common::kPlatformAmiga, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 784) }, @@ -2632,7 +2634,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.005", 0, "3540d1cc84d674cf4b2c898b88a3b563", 790296}, {"resource.006", 0, "ade814bc4d56244c156d9e9bcfebbc11", 664085}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformAmiga, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 784) }, @@ -2648,7 +2650,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.005", 0, "10ee1709e6559c724676d058199b75b5", 818745}, {"resource.006", 0, "67fb188b191d88efe8414af6ea297b93", 672675}, {NULL, 0, NULL, 0}}, Common::DE_DEU, Common::kPlatformAmiga, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 744) // TODO: best bet, exe seems packed }, @@ -2670,7 +2672,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.map", 0, "a18088c8aceb06025dbc945f29e02935", 5124}, {"resource.000", 0, "e1f46832cd2458796028e054a0466031", 5502009}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 200) }, @@ -2681,7 +2683,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.map", 0, "71ccf4f82ac4efb588731acfb7bf2603", 5646}, {"resource.000", 0, "e1f46832cd2458796028e054a0466031", 933928}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 200) }, @@ -2697,7 +2699,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.004", 0, "ff9c87da3bc53473fdee8b9d3edbc93c", 1200631}, {"resource.005", 0, "e33019ac19f755ae33fbf49b4fc9066c", 1053294}, {NULL, 0, NULL, 0}}, Common::EN_ANY, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 200) }, @@ -2713,7 +2715,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.005", 0, "47ee647b5b12232d27e63cc627c25899", 1156765}, {"resource.006", 0, "dfb023e4e2a1e7a00fa18f9ede72a91b", 924059}, {NULL, 0, NULL, 0}}, Common::DE_DEU, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 200) }, @@ -2728,7 +2730,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.004", 0, "4277c61bed40a50dadc4b5a344520af2", 1251000}, {"resource.005", 0, "5f885abd335978e2fd4e5f886d7676c8", 1102880}, {NULL, 0, NULL, 0}}, Common::IT_ITA, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 200) }, @@ -2744,7 +2746,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.004", 0, "776fba81c110d1908776232cbe190e20", 1253752}, {"resource.005", 0, "55fae26c2a92f16ef72c1e216e827c0f", 1098328}, {NULL, 0, NULL, 0}}, Common::ES_ESP, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 200) }, @@ -2758,7 +2760,7 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.002", 0, "74c62fa2146ff3b3b2ea2b3fb95b9af9", 1140801}, {"resource.003", 0, "42a307941edeb1a3be31daeb2e4be90b", 1088408}, {NULL, 0, NULL, 0}}, Common::ES_ESP, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, SCI_VERSION(1, 000, 200) }, @@ -2774,9 +2776,9 @@ static const struct SciGameDescription SciGameDescriptions[] = { {"resource.004", 0, "c06350184a490c10eb4585fff0aa3192", 1254368}, {"resource.005", 0, "b8d6efbd3235329bfe844c794097b2c9", 1098717}, {NULL, 0, NULL, 0}}, Common::DE_DEU, Common::kPlatformPC, 0}, - 0, + GF_FOR_SCI1_200_OR_LATER, SCI_VERSION_AUTODETECT, - SCI_VERSION(1, 000, 030) + SCI_VERSION(1, 000, 200) }, // Space Quest 5 - English DOS (from the Space Quest Collection) diff --git a/engines/sci/engine/game.cpp b/engines/sci/engine/game.cpp index ca88ff1731..ed7564e0b7 100644 --- a/engines/sci/engine/game.cpp +++ b/engines/sci/engine/game.cpp @@ -29,12 +29,12 @@ #include "sci/sci.h" #include "sci/scicore/resource.h" #include "sci/engine/state.h" -#include "sci/scicore/versions.h" #include "sci/engine/kernel.h" #include "sci/engine/kernel_types.h" #include "sci/gfx/gfx_widgets.h" #include "sci/gfx/gfx_state_internal.h" // required for GfxPort, GfxVisual #include "sci/gfx/menubar.h" +#include "sci/scicore/versions.h" namespace Sci { @@ -445,8 +445,7 @@ int script_init_engine(EngineState *s, sci_version_t version) { s->bp_list = NULL; // No breakpoints defined s->have_bp = 0; - if (s->version >= SCI_VERSION_FTU_LOFS_ABSOLUTE && - s->version < SCI_VERSION(1, 001, 000)) + if (s->flags & GF_SCI1_LOFSABSOLUTE && s->version < SCI_VERSION(1, 001, 000)) s->seg_manager->setExportWidth(1); else s->seg_manager->setExportWidth(0); diff --git a/engines/sci/engine/kmovement.cpp b/engines/sci/engine/kmovement.cpp index ba1f4705cb..7acb9c2e67 100644 --- a/engines/sci/engine/kmovement.cpp +++ b/engines/sci/engine/kmovement.cpp @@ -23,6 +23,7 @@ * */ +#include "sci/sci.h" #include "sci/scicore/resource.h" #include "sci/engine/state.h" #include "sci/engine/kernel.h" diff --git a/engines/sci/engine/kscripts.cpp b/engines/sci/engine/kscripts.cpp index 83128786b5..3ce2ebb5a7 100644 --- a/engines/sci/engine/kscripts.cpp +++ b/engines/sci/engine/kscripts.cpp @@ -23,6 +23,7 @@ * */ +#include "sci/sci.h" #include "sci/scicore/resource.h" #include "sci/engine/state.h" #include "sci/engine/kernel_types.h" diff --git a/engines/sci/engine/ksound.cpp b/engines/sci/engine/ksound.cpp index db7c0651a7..421816fbcd 100644 --- a/engines/sci/engine/ksound.cpp +++ b/engines/sci/engine/ksound.cpp @@ -23,10 +23,12 @@ * */ +#include "sci/sci.h" #include "sci/engine/state.h" #include "sci/sfx/player.h" #include "sci/engine/kernel.h" #include "sci/engine/vm.h" // for Object +#include "sci/scicore/versions.h" namespace Sci { diff --git a/engines/sci/engine/savegame.h b/engines/sci/engine/savegame.h index eeaf223510..f53dbb4956 100644 --- a/engines/sci/engine/savegame.h +++ b/engines/sci/engine/savegame.h @@ -29,7 +29,7 @@ #include "common/scummsys.h" #include "common/str.h" -#include "sci/scicore/versions.h" +#include "sci/sci.h" namespace Sci { diff --git a/engines/sci/engine/state.h b/engines/sci/engine/state.h index 1a98cc4349..d8975a0aae 100644 --- a/engines/sci/engine/state.h +++ b/engines/sci/engine/state.h @@ -35,9 +35,9 @@ namespace Common { class WriteStream; } +#include "sci/sci.h" #include "sci/scicore/vocabulary.h" #include "sci/scicore/resource.h" - #include "sci/scicore/versions.h" #include "sci/engine/kernel.h" // for kfunct_sig_pair_t #include "sci/engine/script.h" #include "sci/engine/seg_manager.h" diff --git a/engines/sci/engine/vm.cpp b/engines/sci/engine/vm.cpp index 46944eb020..83e1f0a448 100644 --- a/engines/sci/engine/vm.cpp +++ b/engines/sci/engine/vm.cpp @@ -1239,13 +1239,15 @@ void run_vm(EngineState *s, int restoring) { case 0x39: // lofsa s->r_acc.segment = xs->addr.pc.segment; - if (s->version >= SCI_VERSION(1, 001, 000)) + if (s->version >= SCI_VERSION(1, 001, 000)) { s->r_acc.offset = opparams[0] + local_script->script_size; - else - if (s->version >= SCI_VERSION_FTU_LOFS_ABSOLUTE) + } else { + if (s->flags & GF_SCI1_LOFSABSOLUTE) s->r_acc.offset = opparams[0]; else s->r_acc.offset = xs->addr.pc.offset + opparams[0]; + } + #ifndef DISABLE_VALIDATIONS if (s->r_acc.offset >= code_buf_size) { sciprintf("VM: lofsa operation overflowed: "PREG" beyond end" @@ -1258,7 +1260,7 @@ void run_vm(EngineState *s, int restoring) { case 0x3a: // lofss r_temp.segment = xs->addr.pc.segment; - if (s->version >= SCI_VERSION_FTU_LOFS_ABSOLUTE) + if (s->flags & GF_SCI1_LOFSABSOLUTE) r_temp.offset = opparams[0]; else r_temp.offset = xs->addr.pc.offset + opparams[0]; diff --git a/engines/sci/engine/vm.h b/engines/sci/engine/vm.h index c916ccb61d..67b005ad3e 100644 --- a/engines/sci/engine/vm.h +++ b/engines/sci/engine/vm.h @@ -29,7 +29,6 @@ /* VM and kernel declarations */ //#include "common/serializer.h" -#include "sci/scicore/versions.h" // for sci_version_t #include "sci/engine/vm_types.h" // for reg_t #include "common/util.h" @@ -37,6 +36,8 @@ namespace Sci { class SegManager; +struct EngineState; +typedef int sci_version_t; enum MemObjectType { MEM_OBJ_INVALID = 0, diff --git a/engines/sci/exereader.cpp b/engines/sci/exereader.cpp index 8c8a599e6c..450bb15681 100644 --- a/engines/sci/exereader.cpp +++ b/engines/sci/exereader.cpp @@ -25,8 +25,8 @@ #include "common/endian.h" +#include "sci/sci.h" #include "sci/exereader.h" -#include "sci/scicore/versions.h" namespace Sci { diff --git a/engines/sci/sci.h b/engines/sci/sci.h index 6e44bf1650..b682ffaf48 100644 --- a/engines/sci/sci.h +++ b/engines/sci/sci.h @@ -34,6 +34,7 @@ namespace Sci { class Console; +struct EngineState; // our engine debug levels enum kDebugLevels { @@ -76,6 +77,14 @@ enum SciGameVersions { SCI_VERSION_32 = 8 }; +#define SCI_VERSION(_major_, _minor_, _patchlevel_) (((_major_)<<20) | ((_minor_)<<10) | _patchlevel_) +/* This allows version numbers to be compared directly */ + +#define SCI_VERSION_MAJOR(_version_) ((_version_) >> 20) +#define SCI_VERSION_MINOR(_version_) (((_version_) >> 10) & 0x3ff) +#define SCI_VERSION_PATCHLEVEL(_version_) ((_version_) & 0x3ff) +#define SCI_VERSION_IGNORE_PATCHLEVEL(_version_) ((_version) & ~0x3ff) + enum SciGameFlags { /* ** SCI0 flags @@ -109,11 +118,11 @@ enum SciGameFlags { ** SCI1 flags */ - /* Applies to all versions from 1.000.200 onwards - ** In later SCI1 versions, the argument of lofs[as] - ** instructions is absolute rather than relative. + /* Applies to all SCI1 versions after 1.000.200 + ** In late SCI1 versions, the argument of lofs[as] instructions + ** is absolute rather than relative. */ - GF_LOFSABSOLUTE = (1 << 3), + GF_SCI1_LOFSABSOLUTE = (1 << 3), /* Applies to all versions from 1.000.510 onwards ** kDoSound() is different than in earlier SCI1 versions. diff --git a/engines/sci/scicore/versions.h b/engines/sci/scicore/versions.h index b1eed18748..0c2b131d10 100644 --- a/engines/sci/scicore/versions.h +++ b/engines/sci/scicore/versions.h @@ -30,14 +30,6 @@ namespace Sci { -#define SCI_VERSION(_major_, _minor_, _patchlevel_) (((_major_)<<20) | ((_minor_)<<10) | _patchlevel_) -/* This allows version numbers to be compared directly */ - -#define SCI_VERSION_MAJOR(_version_) ((_version_) >> 20) -#define SCI_VERSION_MINOR(_version_) (((_version_) >> 10) & 0x3ff) -#define SCI_VERSION_PATCHLEVEL(_version_) ((_version_) & 0x3ff) -#define SCI_VERSION_IGNORE_PATCHLEVEL(_version_) ((_version) & ~0x3ff) - /* Version number guide: ** - Always use the version number of the first known version to have a special feature. ** - Don't assume that special feature changes are linked just because they appeared to change @@ -46,19 +38,9 @@ namespace Sci { ** - "FTU" means "First To Use" */ -#define SCI_VERSION_FTU_LOFS_ABSOLUTE SCI_VERSION(1,000,200) -/* First version known to do this: ? - In later versions (SCI1 and beyond), the argument of lofs[as] - instructions is absolute rather than relative. -*/ - #define SCI_VERSION_FTU_DOSOUND_VARIANT_2 SCI_VERSION(1,000,510) -typedef int sci_version_t; - -struct EngineState; - } // End of namespace Sci #endif // SCI_SCICORE_VERSIONS_H diff --git a/engines/sci/scicore/vocabulary.h b/engines/sci/scicore/vocabulary.h index 2124ed36d8..d0c807aebf 100644 --- a/engines/sci/scicore/vocabulary.h +++ b/engines/sci/scicore/vocabulary.h @@ -31,7 +31,7 @@ #include "common/hash-str.h" #include "common/list.h" -#include "sci/scicore/versions.h" +#include "sci/sci.h" namespace Sci { |