Add simon1talkie and simon2talkie targets

svn-id: r5413
This commit is contained in:
Travis Howell 2002-11-05 10:36:31 +00:00
parent ca785239c0
commit 2f270bfd58
7 changed files with 31 additions and 24 deletions

7
README
View File

@ -46,7 +46,7 @@ be playable to the end:
Day Of The Tentacle [Game: tentacle]
Sam & Max [Game: samnmax]
The Dig [Game: dig]
Simon The Sorcerer [Game: simon1dos/simon1win]
Simon The Sorcerer [Game: simon1dos/simon1talkie/simon1win]
The following games should load, but are not yet fully playable. Play these at
@ -71,11 +71,6 @@ features that sometimes make it impossible to finish the game. Save often,
and please file a bug report (details on submitted bug reports are below)
if you discover such a bug.
There is also a known problem with some versions of Simon the Sorcerer
not loading correctly. If you experience problems please try both the
simon1dos and simon1win game targets, some versions of Simon are labelled
'Windows' but use the DOS game files.
Supported Platforms:
-------------------

View File

@ -504,9 +504,11 @@ const VersionSettings version_settings[] = {
/* Simon the Sorcerer 1 & 2 (not SCUMM games) */
{"simon1dos", "Simon the Sorcerer 1 for DOS", GID_SIMON_FIRST+0, 99, 99, 99, 0},
{"simon2dos", "Simon the Sorcerer 2 for DOS", GID_SIMON_FIRST+1, 99, 99, 99, 0},
{"simon1win", "Simon the Sorcerer 1 for Windows", GID_SIMON_FIRST+2, 99, 99, 99, 0},
{"simon2win", "Simon the Sorcerer 2 for Windows", GID_SIMON_FIRST+3, 99, 99, 99, 0},
{"simon1demo", "Simon the Sorcerer 1 for DOS (demo)", GID_SIMON_FIRST+4, 99, 99, 99, 0},
{"simon1talkie", "Simon the Sorcerer 1 Talkie for DOS", GID_SIMON_FIRST+4, 99, 99, 99, 0},
{"simon2talkie", "Simon the Sorcerer 2 Talkie for DOS", GID_SIMON_FIRST+5, 99, 99, 99, 0},
{"simon1win", "Simon the Sorcerer 1 Talkie for Windows", GID_SIMON_FIRST+6, 99, 99, 99, 0},
{"simon2win", "Simon the Sorcerer 2 Talkie for Windows", GID_SIMON_FIRST+7, 99, 99, 99, 0},
{"simon1demo", "Simon the Sorcerer 1 for DOS (demo)", GID_SIMON_FIRST+8, 99, 99, 99, 0},
/* Scumm Version 8 */
{"comi", "The Curse of Monkey Island", GID_CMI, 8, 1, 0,

View File

@ -276,7 +276,7 @@ enum GameId {
/* Simon the Sorcerer */
GID_SIMON_FIRST = 20,
GID_SIMON_LAST = GID_SIMON_FIRST + 4,
GID_SIMON_LAST = GID_SIMON_FIRST + 8,
};
enum GameFeatures {

View File

@ -386,7 +386,7 @@ int SimonState::runScript()
break;
case 67:{ /* set array 3 and 4 */
if (_game & GAME_WIN) {
if (_game & GAME_TALKIE || _game & GAME_WIN) {
uint var = getVarOrByte();
uint string_id = getNextStringID();
uint value = getNextWord();
@ -1008,14 +1008,14 @@ int SimonState::runScript()
break;
case 179:{
if (_game == GAME_SIMON1WIN) {
if (_game == GAME_SIMON1TALKIE || _game == GAME_SIMON1WIN) {
uint b = getVarOrByte();
/*uint c = */ getVarOrByte();
uint a = getVarOrByte();
uint d = _array_4[a];
if (d != 0)
talk_with_speech(d, b);
} else if ((_game == GAME_SIMON1DEMO) || (_game == GAME_SIMON1DOS)) {
} else if (_game == GAME_SIMON1DEMO || _game == GAME_SIMON1DOS) {
uint b = getVarOrByte();
uint c = getVarOrByte();
uint a = getVarOrByte();
@ -1040,7 +1040,7 @@ int SimonState::runScript()
}
talk_with_text(b, c, s, tv->a, tv->b, tv->c);
} else if (_game == GAME_SIMON2WIN) {
} else if (_game == GAME_SIMON2TALKIE || _game == GAME_SIMON2WIN) {
uint b = getVarOrByte();
uint c = getVarOrByte();
uint a = getVarOrByte();
@ -1303,7 +1303,7 @@ bool SimonState::o_unk_23(uint a)
void SimonState::o_177()
{
if (_game == GAME_SIMON1WIN) {
if (_game == GAME_SIMON1TALKIE || _game == GAME_SIMON1WIN) {
uint a = getVarOrByte();
/*uint b = */ getVarOrByte();
uint offs;
@ -1348,7 +1348,7 @@ void SimonState::o_177()
talk_with_text(a, b, s, tv->a, tv->b, tv->c);
}
} else if (_game == GAME_SIMON2WIN) {
} else if (_game == GAME_SIMON2TALKIE || _game == GAME_SIMON2WIN) {
uint a = getVarOrByte();
uint b = getVarOrByte();
Child2 *child = (Child2 *)findChildOfType(getNextItemPtr(), 2);

View File

@ -253,12 +253,14 @@ byte *SimonState::readSingleOpcode(File *in, byte *ptr)
const char *const *table;
switch (_game) {
case GAME_SIMON1TALKIE:
case GAME_SIMON1WIN:
table = opcode_arg_table_simon1win;
break;
case GAME_SIMON2DOS:
table = opcode_arg_table_simon2dos;
break;
case GAME_SIMON2TALKIE:
case GAME_SIMON2WIN:
table = opcode_arg_table_simon2win;
break;

View File

@ -1713,6 +1713,7 @@ void SimonState::o_print_str()
switch (_game) {
case GAME_SIMON1TALKIE:
case GAME_SIMON1WIN:
if (string_id != 0xFFFF)
string_ptr = getStringPtrByID(string_id);
@ -1720,6 +1721,7 @@ void SimonState::o_print_str()
speech_id = (uint16)getNextWord();
break;
case GAME_SIMON2TALKIE:
case GAME_SIMON2WIN:
if (string_id != 0xFFFF)
string_ptr = getStringPtrByID(string_id);
@ -1759,6 +1761,7 @@ void SimonState::o_print_str()
switch (_game) {
case GAME_SIMON1TALKIE:
case GAME_SIMON1WIN:
#ifdef USE_TEXT_HACK
if (speech_id != 0) {
@ -1792,6 +1795,7 @@ void SimonState::o_print_str()
talk_with_text(num_1, num_2, (char *)string_ptr, tv->a, tv->b, tv->c);
break;
case GAME_SIMON2TALKIE:
case GAME_SIMON2WIN:
if (speech_id != 0 && num_1 == 1 && !_vk_t_toggle)
talk_with_speech(speech_id, num_1);
@ -4347,7 +4351,7 @@ void SimonState::go()
_sdl_buf = (byte *)calloc(320 * 200, 1);
_sdl_buf_attached = (byte *)calloc(320 * 200, 1);
if (_game == GAME_SIMON2WIN) {
if (_game == GAME_SIMON2TALKIE || _game == GAME_SIMON2WIN) {
gss = &simon2win_settings;
} else if (_game == GAME_SIMON2DOS) {
gss = &simon2dos_settings;
@ -4675,7 +4679,7 @@ bool SimonState::load_game(uint slot)
void SimonState::initSound()
{
/* only read voice file in windows game */
if (_game & GAME_WIN) {
if (_game & GAME_TALKIE || _game & GAME_WIN) {
const char *m = gss->mp3_filename;
const char *s = gss->wav_filename;
const char *s2 = gss->voc_filename;
@ -4985,7 +4989,7 @@ void SimonState::playSound(uint sound)
#ifdef USE_MAD
}
#endif
} else if (_game & GAME_WIN) { /* ? sound simon 1/2 win talkie */
} else if (_game & GAME_TALKIE || _game & GAME_WIN) { /* ? sound simon 1/2 win talkie */
byte *p;
@ -5027,7 +5031,7 @@ void SimonState::playMusic(uint music)
/* Simon 2 dos music isn't supported */
if (_voice_type == FORMAT_WAV) {
midi.shutdown();
if (_game & GAME_WIN) {
if (_game & GAME_TALKIE || _game & GAME_WIN) {
_game_file->seek(_game_offsets_ptr[gss->MUSIC_INDEX_BASE + music], SEEK_SET);
midi.read_all_songs(_game_file);
}
@ -5037,7 +5041,7 @@ void SimonState::playMusic(uint music)
} else if (!(_game & GAME_SIMON2)){
midi.shutdown();
if (_game & GAME_WIN) {
if (_game & GAME_TALKIE || _game & GAME_WIN) {
_game_file->seek(_game_offsets_ptr[gss->MUSIC_INDEX_BASE + music], SEEK_SET);
midi.read_all_songs_old(_game_file);
} else {

View File

@ -114,12 +114,16 @@ public:
enum {
GAME_SIMON2 = 1,
GAME_WIN = 2,
GAME_TALKIE = 4,
GAME_DEMO = 8,
GAME_SIMON1DOS = 0,
GAME_SIMON1WIN = GAME_WIN,
GAME_SIMON2DOS = GAME_SIMON2,
GAME_SIMON2WIN = GAME_SIMON2 + GAME_WIN,
GAME_SIMON1DEMO = 4,
GAME_SIMON1TALKIE = GAME_TALKIE,
GAME_SIMON2TALKIE = GAME_SIMON2 + GAME_TALKIE,
GAME_SIMON1WIN = GAME_WIN + GAME_TALKIE,
GAME_SIMON2WIN = GAME_SIMON2 + GAME_WIN + GAME_TALKIE,
GAME_SIMON1DEMO = GAME_DEMO,
};
typedef enum {