Skip to content

Commit

Permalink
Minor bugfix
Browse files Browse the repository at this point in the history
  • Loading branch information
KinoMyu committed Apr 1, 2018
1 parent 15ab396 commit 45c91a5
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions src/mainwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -294,9 +294,12 @@ void MainWindow::play()
{
BASS_ChannelPause(mix_stream);
BASS_ChannelSetPosition(bgm->get_decode_channel(), 0, BASS_POS_BYTE);
for(int i = 0; i < NUM_IDOLS; ++i)
if(!isusotsuki)
{
BASS_ChannelSetPosition(idols[i]->get_decode_channel(), 0, BASS_POS_BYTE);
for(int i = 0; i < NUM_IDOLS; ++i)
{
BASS_ChannelSetPosition(idols[i]->get_decode_channel(), 0, BASS_POS_BYTE);
}
}
}
// Clear buffer if player was paused
Expand All @@ -321,9 +324,12 @@ void MainWindow::reset()
BASS_ChannelPause(mix_stream);
}
// Set positions and flush buffer
for(int i = 0; i < NUM_IDOLS; ++i)
if(!isusotsuki)
{
BASS_Mixer_ChannelSetPosition(idols[i]->get_decode_channel(), 0, BASS_POS_BYTE);
for(int i = 0; i < NUM_IDOLS; ++i)
{
BASS_Mixer_ChannelSetPosition(idols[i]->get_decode_channel(), 0, BASS_POS_BYTE);
}
}
BASS_Mixer_ChannelSetPosition(bgm->get_decode_channel(), 0, BASS_POS_BYTE | BASS_POS_MIXER_RESET);
}
Expand Down

0 comments on commit 45c91a5

Please sign in to comment.