Skip to content
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

(cheevos) add option to play custom sound on achievement unlock #11010

Merged
merged 1 commit into from Jul 12, 2020

Conversation

Jamiras
Copy link
Contributor

@Jamiras Jamiras commented Jul 11, 2020

Description

Adds the ability to play a sound file (assets/sounds/unlock.*) when an achievement unlocks.

Builds on #8106, but doesn't require Menu Sounds to be enabled.

General question: How do we provide a default sound file so users won't complain about it not working when they enable it?

Related Issues

#10503

Related Pull Requests

n/a

Reviewers

@twinaphex @meleu @Sanaki

@@ -1141,7 +1141,7 @@ static const camera_driver_t *camera_drivers[] = {

#define AUDIO_BUFFER_FREE_SAMPLES_COUNT (8 * 1024)

#define MENU_SOUND_FORMATS "ogg|mod|xm|s3m|mp3|flac"
#define MENU_SOUND_FORMATS "ogg|mod|xm|s3m|mp3|flac|wav"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a specific reason wav was not included in this list? I did notice that the rwav library didn't like any of my .wav files that contained metadata.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can confirm the wav file won't play if any metadata is present. I wouldn't be surprised if that's why it was excluded. Easy to miss that being the cause in testing.

Copy link
Contributor

@Sanaki Sanaki left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested and confirmed working with wav (tagless), ogg, and flac. As noted, any metadata in the wav file will prevent playback.
Unlock sound file should be added to https://github.com/libretro/retroarch-assets/tree/master/sounds

@meleu
Copy link
Contributor

meleu commented Jul 12, 2020

Built and tested here, and hey! That's really cool! 😄
Working as expected.

@hizzlekizzle
Copy link
Contributor

I think people will be very excited for this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants