Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
A voice is considered running if and only if
runningequals 1, not ifrunningis not equal to 0.This fixes https://bugs.dolphin-emu.org/issues/12508 because for some reason The Sims 2 - Castaway sets
runningto 8 when a stream finishes playing; previously our AX HLE would just loop the voice and eventually crash after accessing invalid memory addresses.Thanks to JMC47 and delroth's help, I've verified that this is the correct check for the following ucodes:
GC:
Wii:
And while I was fixing the running check, I noticed that the is_stream field was also being handled incorrectly, so I've fixed that as well.
This PR also removes redundant accelerator end checks for AX Wii. The DSP accelerator already tracks whether the end has been reached and returns 0 when appropriate.