[Scummvm-cvs-logs] SF.net SVN: scummvm: [29548] scummvm/trunk/engines/lure/scripts.cpp
dreammaster at users.sourceforge.net
dreammaster at users.sourceforge.net
Sun Nov 18 06:11:38 CET 2007
Revision: 29548
http://scummvm.svn.sourceforge.net/scummvm/?rev=29548&view=rev
Author: dreammaster
Date: 2007-11-17 21:11:38 -0800 (Sat, 17 Nov 2007)
Log Message:
-----------
Added sounds to endgame animation sequence
Modified Paths:
--------------
scummvm/trunk/engines/lure/scripts.cpp
Modified: scummvm/trunk/engines/lure/scripts.cpp
===================================================================
--- scummvm/trunk/engines/lure/scripts.cpp 2007-11-18 05:10:56 UTC (rev 29547)
+++ scummvm/trunk/engines/lure/scripts.cpp 2007-11-18 05:11:38 UTC (rev 29548)
@@ -46,6 +46,13 @@
static const uint16 *hotspot_dealloc_set[4] = {&dealloc_list_1[0], &dealloc_list_2[0],
&dealloc_list_3[1], &dealloc_list_3[0]};
+// Details used for co-ordination of sounds during the endgame sequence
+static const AnimSoundSequence soundList[] = {
+ {9, 2, 0}, {27, 5, 0}, {24, 3, 0}, {24, 1, 0}, {3, 1, 1}, {3, 1, 2}, {3, 1, 3},
+ {3, 1, 4}, {4, 1, 5}, {7, 4, 6}, {31, 6, 0},
+ {0, 0, 0}
+};
+
/*------------------------------------------------------------------------*/
/*- Script Method List -*/
/*- -*/
@@ -188,25 +195,36 @@
Events &events = Events::getReference();
AnimationSequence *anim;
-// screen.paletteFadeOut();
+ screen.paletteFadeOut();
Sound.killSounds();
+ Sound.loadSection(0xFF10);
mouse.cursorOff();
Palette p(ENDGAME_PALETTE_ID);
- anim = new AnimationSequence(screen, *g_system, ENDGAME_ANIM_ID, p, false);
+ anim = new AnimationSequence(ENDGAME_ANIM_ID, p, true, 9, soundList);
anim->show();
delete anim;
- anim = new AnimationSequence(screen, *g_system, ENDGAME_ANIM_ID + 2, p, false);
+ Sound.killSounds();
+ Sound.musicInterface_Play(6, 0);
+
+ anim = new AnimationSequence(ENDGAME_ANIM_ID + 2, p, false);
anim->show();
- events.interruptableDelay(8000);
+ events.interruptableDelay(13000);
delete anim;
- anim = new AnimationSequence(screen, *g_system, ENDGAME_ANIM_ID + 4, p, false);
+ anim = new AnimationSequence(ENDGAME_ANIM_ID + 4, p, false);
anim->show();
- events.interruptableDelay(30000);
- delete anim;
-
+ if (!events.interruptableDelay(30000)) {
+ // No key yet pressed, so keep waiting
+ while (Sound.musicInterface_CheckPlaying(6) && !events.quitFlag) {
+ if (events.interruptableDelay(20))
+ break;
+ }
+ }
+ delete anim;
+
+ screen.paletteFadeOut();
events.quitFlag = true;
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list