From 04bb7fff2d09663d27c12e3391514ff305b1ef64 Mon Sep 17 00:00:00 2001 From: Travis Howell Date: Sun, 25 Jan 2004 16:48:06 +0000 Subject: Check for demo version. svn-id: r12596 --- queen/music.cpp | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'queen') diff --git a/queen/music.cpp b/queen/music.cpp index 69aeaae393..d3f448540d 100644 --- a/queen/music.cpp +++ b/queen/music.cpp @@ -166,7 +166,8 @@ static const byte mt32_to_gm[128] = { return; } - switch (Sound::_tune[tuneList].mode) { + int mode = (_numSongs == 40) ? Sound::_tuneDemo[tuneList].mode : Sound::_tune[tuneList].mode; + switch (mode) { //Random loop case 0: _randomLoop = true; @@ -187,8 +188,13 @@ static const byte mt32_to_gm[128] = { } int i = 0; - while(Sound::_tune[tuneList].tuneNum[i]) - queueSong(Sound::_tune[tuneList].tuneNum[i++] - 1); + if (_numSongs == 40) { + while(Sound::_tuneDemo[tuneList].tuneNum[i]) + queueSong(Sound::_tuneDemo[tuneList].tuneNum[i++] - 1); + } else { + while(Sound::_tune[tuneList].tuneNum[i]) + queueSong(Sound::_tune[tuneList].tuneNum[i++] - 1); + } if (_randomLoop) _queuePos = randomQueuePos(); -- cgit v1.2.3