-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
music fix - it plays only track 0,1,2,3 and silence ... #472
Comments
it works fine for me, on windows. Also, I thought there was only a single tune that loops forever?? |
oh I guess there are multiple tracks, I never really noticed before. It loops forever for me, though. |
There's a single tune in Amiga though. |
anyone remembers how it works in the original DOS game ? |
It loops through all. However there are version differences - Amiga's one track is longer than the DOS version's 4 track combined, so if you use Amiga music then yes, you can perceive the segments omitted from DOS as new. |
I think GraionDilach is right, I hear one new track in certain Freeserf versions. But in the original game I agree there are multiple tracks that are so similar I assumed they were all one |
two bugs:
-after game start there is problem with music loop - it plays track 0,1,2,3 and then because of bad construction of music loop nonexist 4, simplest fix is replace in file audio-sdlmixer.cc:
AudioSDL::PlayerMIDI::play_track(int track_id) {
line "track_id++;" replace with:
(track_id < (TypeMidiTrackLast-1) ? track_id++ : track_id = 0);
-after disable and reenable music in options there is silence :) so modify in file audio-sdlmixer.cc:
void
AudioSDL::PlayerMIDI::enable(bool enable) {
enabled = enable;
if (!enabled) {
stop();
} else {//fixed start playing when music enabled in options
if (!Mix_PlayingMusic()) {
play_track(0);
}
}
}
The text was updated successfully, but these errors were encountered: