From 84393ab95e7d72484f5c612cee298f91e90221bd Mon Sep 17 00:00:00 2001 From: Filippos Karapetis Date: Thu, 13 Sep 2007 11:21:23 +0000 Subject: The early ITE demos were not interactive svn-id: r28897 --- engines/saga/detection_tables.h | 12 ++++-------- engines/saga/saga.h | 3 ++- engines/saga/sfuncs.cpp | 14 ++++++++++++++ 3 files changed, 20 insertions(+), 9 deletions(-) diff --git a/engines/saga/detection_tables.h b/engines/saga/detection_tables.h index bd0c4eef25..5bb408e947 100644 --- a/engines/saga/detection_tables.h +++ b/engines/saga/detection_tables.h @@ -235,10 +235,8 @@ static const SAGAGameDescription gameDescriptions[] = { }, - // Note: This version is NOT supported yet - // Exiting the faire leads to a crash - // Inherit the earth - MAC Demo version 1 + // Non-interactive demo { { "ite", @@ -257,7 +255,7 @@ static const SAGAGameDescription gameDescriptions[] = { }, GType_ITE, GID_ITE_MACDEMO1, - GF_BIG_ENDIAN_DATA | GF_WYRMKEEP | GF_CD_FX, + GF_BIG_ENDIAN_DATA | GF_WYRMKEEP | GF_CD_FX | GF_NON_INTERACTIVE, ITE_DEFAULT_SCENE, &ITE_Resources, ARRAYSIZE(ITEWINDEMO_GameFonts), @@ -301,10 +299,8 @@ static const SAGAGameDescription gameDescriptions[] = { }, - // Note: This version is NOT supported yet - // Exiting the faire leads to a crash - // Inherit the earth - Win32 Demo version 1 + // Non-interactive demo { { "ite", @@ -322,7 +318,7 @@ static const SAGAGameDescription gameDescriptions[] = { }, GType_ITE, GID_ITE_WINDEMO1, - GF_WYRMKEEP | GF_CD_FX, + GF_WYRMKEEP | GF_CD_FX | GF_NON_INTERACTIVE, ITE_DEFAULT_SCENE, &ITE_Resources, ARRAYSIZE(ITEWINDEMO_GameFonts), diff --git a/engines/saga/saga.h b/engines/saga/saga.h index fc74702143..8016fb9e65 100644 --- a/engines/saga/saga.h +++ b/engines/saga/saga.h @@ -158,7 +158,8 @@ enum GameFeatures { GF_WYRMKEEP = 1 << 1, GF_CD_FX = 1 << 2, GF_SCENE_SUBSTITUTES = 1 << 3, - GF_COMPRESSED_SOUNDS = 1 << 4 + GF_COMPRESSED_SOUNDS = 1 << 4, + GF_NON_INTERACTIVE = 1 << 5 }; enum VerbTypeIds { diff --git a/engines/saga/sfuncs.cpp b/engines/saga/sfuncs.cpp index 1697e6c92f..4dc394130c 100644 --- a/engines/saga/sfuncs.cpp +++ b/engines/saga/sfuncs.cpp @@ -332,6 +332,20 @@ void Script::sfMainMode(SCRIPTFUNC_PARAMS) { if (_vm->getGameType() == GType_ITE) setPointerVerb(); + + // The early Windows and Mac demos of ITE were non-interactive. In those demos, + // the intro is shown and then when the first scene is shown, there's a dialog + // thanking the user for playing the demo and asking him to buy the full game, + // without allowing him to continue any further. The game data itself for these + // demos does not contain any scripts for the first scene (i.e. there's no text + // in the game data to look at Rif's silver medallion). Also, there are no more + // scenes apart from the Grand Tournament scene. This opcode is called in those + // demos, and I assume that its use there is to just show the popup window and + // exit the game. Therefore, once this opcode is called in the older ITE demos, + // exit the game. Known non-interactive demos are GID_ITE_MACDEMO1 and + // GID_ITE_WINDEMO1 + if (_vm->getFeatures() & GF_NON_INTERACTIVE) + _vm->shutDown(); } // Script function #6 (0x06) blocking -- cgit v1.2.3