diff options
| -rw-r--r-- | simon/debug.cpp | 2 | ||||
| -rw-r--r-- | simon/items.cpp | 2 | ||||
| -rw-r--r-- | simon/simon.cpp | 52 | 
3 files changed, 34 insertions, 22 deletions
| diff --git a/simon/debug.cpp b/simon/debug.cpp index ec171be5f3..df8b73280b 100644 --- a/simon/debug.cpp +++ b/simon/debug.cpp @@ -39,7 +39,7 @@ byte *SimonState::dumpOpcode(byte *p) {  		return NULL;  	if (_game == GAME_SIMON1DOS || _game == GAME_SIMON1DEMO) {  	st = s = simon1dos_opcode_name_table[opcode]; -	} else if (_game == GAME_SIMON1TALKIE || _game == GAME_SIMON1WIN) { +	} else if (_game == GAME_SIMON1CD32 || _game == GAME_SIMON1TALKIE || _game == GAME_SIMON1WIN) {  	st = s = simon1talkie_opcode_name_table[opcode];  	} else if (_game == GAME_SIMON2TALKIE || _game == GAME_SIMON2WIN) {  	st = s = simon2talkie_opcode_name_table[opcode]; diff --git a/simon/items.cpp b/simon/items.cpp index cbde6372af..e69b85886e 100644 --- a/simon/items.cpp +++ b/simon/items.cpp @@ -1228,7 +1228,7 @@ void SimonState::o_177() {  		tv = getThreeValues(a);  	} -	if (_game == GAME_SIMON1TALKIE || _game == GAME_SIMON1WIN) { +	if (_game == GAME_SIMON1CD32 || _game == GAME_SIMON1TALKIE || _game == GAME_SIMON1WIN) {  		if (child != NULL && child->avail_props & 0x200) {  			uint offs = getOffsetOfChild2Param(child, 0x200);  			if (!_subtitles) diff --git a/simon/simon.cpp b/simon/simon.cpp index ec5ac17033..573df4459d 100644 --- a/simon/simon.cpp +++ b/simon/simon.cpp @@ -1430,6 +1430,7 @@ uint SimonState::item_get_icon_number(Item *item) {  void SimonState::loadIconFile() {  	File in;  	if (_game & GF_AMIGAS) +		/* TODO Add support for decruncher */  		in.open("icon.pkd", _gameDataPath);  	else  		in.open("ICON.DAT", _gameDataPath); @@ -4419,6 +4420,7 @@ void SimonState::read_vga_from_datfile_1(uint vga_id) {  		if (_game == GAME_SIMON1CD32) {  			sprintf(buf, "0%d.out", vga_id);   		} else if (_game == GAME_SIMON1AMIGA) { +			/* TODO Add support for decruncher */  			sprintf(buf, "0%d.pkd", vga_id);   		} else {  			sprintf(buf, "0%d.VGA", vga_id);  @@ -4452,6 +4454,7 @@ byte *SimonState::read_vga_from_datfile_2(uint id) {  		if (_game == GAME_SIMON1CD32) {  			sprintf(buf, "%.3d%d.out", id >> 1, (id & 1) + 1);  		} else if (_game == GAME_SIMON1AMIGA) { +			/* TODO Add support for decruncher */  			sprintf(buf, "%.3d%d.pkd", id >> 1, (id & 1) + 1);  		} else {  			sprintf(buf, "%.3d%d.VGA", id >> 1, (id & 1) + 1); @@ -4734,7 +4737,7 @@ void SimonState::go() {  		_subtitles = true;  	midi._midi_sfx_toggle = false; -	 +  	while (1) {  		hitarea_stuff();  		handle_verb_clicked(_verb_hitarea); @@ -5054,28 +5057,37 @@ void SimonState::playMusic(uint music_unk, uint music) {  		_vc70_var1 = 0xFFFF;  		_vc72_var3 = 0xFFFF;  		_midi_unk2 = 0xFFFF; -	} else if (!(_game & GF_DEMO) && !(_game & GF_AMIGAS)){ // Simon 1 music -		midi.shutdown(); -		if (_game & GF_WIN) {	 -			_game_file->seek(_game_offsets_ptr[gss->MUSIC_INDEX_BASE + music], SEEK_SET); -			midi.read_all_songs(_game_file, music); -		} else if (_game & GF_TALKIE) { -			_game_file->seek(_game_offsets_ptr[gss->MUSIC_INDEX_BASE + music], SEEK_SET); -			midi.read_all_songs_old(_game_file, music); +	} else { // Simon 1 music +		if (_game & GF_AMIGAS) { +			if (_game != GAME_SIMON1CD32) { +				/* TODO Add support for decruncher */ +			} +			/* TODO Add Protracker support for simon1amiga/cd32 */ +		} else if (_game & GF_DEMO) { +			/* TODO Add music support for simon1demo */  		} else { -			char buf[50]; -			File *f = new File(); -			sprintf(buf, "MOD%d.MUS", music); -			f->open(buf, _gameDataPath); -			if (f->isOpen() == false) { -				warning("Can't load music from '%s'", buf); -				return; +			midi.shutdown(); +			if (_game & GF_WIN) {	 +				_game_file->seek(_game_offsets_ptr[gss->MUSIC_INDEX_BASE + music], SEEK_SET); +				midi.read_all_songs(_game_file, music); +			} else if (_game & GF_TALKIE) { +				_game_file->seek(_game_offsets_ptr[gss->MUSIC_INDEX_BASE + music], SEEK_SET); +				midi.read_all_songs_old(_game_file, music); +			} else { +				char buf[50]; +				File *f = new File(); +				sprintf(buf, "MOD%d.MUS", music); +				f->open(buf, _gameDataPath); +				if (f->isOpen() == false) { +					warning("Can't load music from '%s'", buf); +					return; +				} +				midi.read_all_songs_old(f, music); +				delete f;  			} -			midi.read_all_songs_old(f, music); -			delete f; +			midi.initialize(); +			midi.play();  		} -		midi.initialize(); -		midi.play();  	}  } | 
