Skip to content

Commit

Permalink
Fixes hanging audio when stopping sound effect on JVM JNA/OpenAL (#887)
Browse files Browse the repository at this point in the history
  • Loading branch information
soywiz authored Jul 27, 2022
1 parent fa1ba0c commit 810eff0
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -333,7 +333,7 @@ class OpenALSoundNoStream(
var times = params.times
var startTime = params.startTime
try {
while (times.hasMore) {
while (times.hasMore && !stopped) {
times = times.oneLess
channel.reset()
AL.alSourcef(source, AL.AL_SEC_OFFSET, startTime.seconds.toFloat())
Expand Down

0 comments on commit 810eff0

Please sign in to comment.