Please sign in to comment.
CocosDenshion Android - missing sound effects with some conditions
Android SoundPool.load returns 0 if sound might not be loaded - for example, it does not exist. Previously - 0 has been ignored and incorrectly written to HashMap, so it was not possible to understand on the application side that something goes wrong (and use some additional workaround). Use case: 1) On the game loading - preload all possible sound effects (to speed up their playing later, when it will be needed) 2) Game APK does not have any sound file, they are downloaded later in a separate thread. 3) Application tries to play sound effects as usual, when needed. So due to this bug - as there was no any sound file exist during the game loading - internal HashMap contains incorrect 0 as id for every effect, and there is no any sound effect during the first application start.
- Loading branch information...
Showing with 9 additions and 1 deletion.