revert last change, it's too much experimental

svn-id: r17349
This commit is contained in:
Paweł Kołodziejski 2005-04-03 17:11:06 +00:00
parent 2296e4e02e
commit aa50d6d7b0

View File

@ -286,40 +286,27 @@ void IMuseDigital::playComiMusic(const char *songName, const imuseComiTable *tab
switch(table->opcode) { switch(table->opcode) {
case 0: case 0:
fadeOutMusic(120);
break;
case 8: case 8:
case 9: case 9:
{
int soundId = getCurMusicSoundId();
setHookId(soundId, hookId);
break;
}
case 1:
fadeOutMusic(120); fadeOutMusic(120);
break;
case 1:
if (table->filename[0] == 0) { if (table->filename[0] == 0) {
fadeOutMusic(120);
return; return;
} }
fadeOutMusic(120);
startMusic(table->filename, table->soundId, 0, 1); startMusic(table->filename, table->soundId, 0, 1);
setFade(table->soundId, 127, 120); setFade(table->soundId, 127, 120);
break; break;
case 2: case 2:
{ if (table->filename[0] == 0) {
if (table->filename[0] == 0) { fadeOutMusic(60);
fadeOutMusic(60); return;
return;
}
char *soundName = getCurMusicSoundName();
if ((strcmp(soundName, table->filename) == 0)) {
int soundId = getCurMusicSoundId();
setFade(soundId, 127, table->fadeOut60TicksDelay);
setHookId(soundId, hookId);
} else {
fadeOutMusic(120);
startMusic(table->filename, table->soundId, table->hookId, 127);
}
break;
} }
fadeOutMusic(table->fadeOut60TicksDelay);
startMusic(table->filename, table->soundId, table->hookId, 127);
break;
case 3: case 3:
case 4: case 4:
case 12: case 12:
@ -327,9 +314,9 @@ void IMuseDigital::playComiMusic(const char *songName, const imuseComiTable *tab
fadeOutMusic(60); fadeOutMusic(60);
return; return;
} }
fadeOutMusic(table->fadeOut60TicksDelay);
if ((!sequence) && (table->atribPos != 0) && if ((!sequence) && (table->atribPos != 0) &&
(table->atribPos == _comiStateMusicTable[_curMusicState].atribPos)) { (table->atribPos == _comiStateMusicTable[_curMusicState].atribPos)) {
fadeOutMusic(table->fadeOut60TicksDelay);
startMusic(table->filename, table->soundId, 0, 127); startMusic(table->filename, table->soundId, 0, 127);
return; return;
} }