audio feedback for UI elements #61
Labels
No Label
bug
Critical Priority
duplicate
enhancement
help wanted
High Priority
Low Priority
Medium Priority
Meta
needs more info
question
refactor
wontfix
bug
Critical Priority
duplicate
enhancement
help wanted
High Priority
invalid
Low Priority
Medium Priority
Meta
question
wontfix
No Milestone
No project
No Assignees
4 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: Cavemanon/SnootGame#61
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
pretty self explanatory: sounds / audio cues for certain UI elements, including but not limited to:
@mapanon has some awesome sound fx prepared for this already, just needs to be programmed in. will upload the sounds in the following post.
Note that these sounds and how I named them are absolutely flexible, use them however you see fit. If you need more sounds or revisions to those sounds, ask away.
While I appreciate the sounds, I am not sure if we need them. The menu music is so good that a ui sound would feel a bit jarring.
I am happy to jump on this and start working on it if the "head honchos" decide we need them.
Kind of what I feel too. I just conceptualized them and asked them if this was alright to put in and they said yes, so I figure if they don't work they can always be stubbed out later or replaced with silence.
In my fork, I added the sounds for the UI. I used uiClick for most stuff, with the exception of the Update functions (request, fail and success).
I wanted them to go on a separate channel, but apparently you can't have that with buttons. Or at least I could not find a way in the docs, so they are currently piggibacking on sounds (and the volume control is there too).
Have a look - and if anyone knows more about channels + buttons please enlighten me. Aside from custom functions, I can't see an official way of doing this. If we need to separate out the volume control for these ui sounds at all, that is.
@Nio Chuck it into voice
Happy to do this, though I'm not sure if it will solve the issue of not having fine control over the volume of the UI sounds specifically as the issue is I can't see where the sound played by the button is actually assigned to a channel. I think that it is assigned to the sounds channel by default and there is no built-in renpy way of assigning it to a different channel (hence I mentioned a hack could do it potentially, but it will likely not be pretty).
I was originally going to replace uiClick with something else, but my attempts didn't feel as correct as with the OG uiClick. You can have my attempts and use them if you want.
What I am replacing is uiNotification, just to remove the little click that's in it.
(low prio + dont want to rush this so i'm moving to back to update-6 for now)
Do we need to go down the custom function route for this one or is it OK as is? Not entire sure what other sounds use the "sounds" channel.
If we go down the alternate route, my current understanding is that we need to have a separate channel for the UI sounds, separate control slider and a custom function to add as an action to all buttons (so that it ties the right channel to it). I can do all that, but I would like to know if we are going for that or if how it is currently implemented in my fork fits what we need just fine.
@Nio, as I said before, you can set the hover sounds into 'voice'
there are actually multiple channels that aren't listed (or easy to find documenation on) but few mixers (sound, music, voice, audio)
so you could make a new channel + put it into different mixer altogether
renpy.music.register_channel(name, mixer=None, loop=None ..
Ah OK, this was the missing bit. Will do this then, thanks.
This is ready for inspection in my fork. I have put it on the voice mixer, in a new channel called 'uisounds' .
The docos are hinting at there being a way to register a new mixer, I think. But I couldn't get any further info on it yet. Starting to think that this is a running theme with Renpy (or maybe I just haven't found the better sources yet).
EDIT: If anyone was looking, sorry, I forgot to push... It is really in there now.
@Nio, You can't directly register mixers but when it creates all of the mixers it looks into the registered channels' mixers.
renpy/audio/audio.py
so all you really have to do is
The only thing left after doing some of the changes and the prefrences UI is to merge with the MU6 branch, briefly looking at your repo.
Thanks, I've added this to my fork.
I need to get into the habit of looking into the renpy code for the nitty-gritty.