Yes. Feel free to use it in a commercial project.
I updated the description to make that clear.
If you mean audio file dialogue? I didn't implement that and I don't know how to do it. I think doing that without syncing with the text is a HUGE endeavor.
If you mean just random sounds which are generated based on the letters, it should happen automatically by ren'py. I didn't do anything about that.
If you are starting a sound when dialogue starts and you don't handle the remaining events, you do get that result. To make it stop in the latter situation, you have to process the other events to control those files.
Also, how do you handle when the user changes settings to use a different text speed? Are you also changing the speed of the dialogue?
sorry it took forever to reply to this! i had a look at the project that this was based on, and was surprised to see that they actually had a feature for this, in "Version 2". essentially, im just using this code here (although in a different audio channel) from the renpy documentation to have text bleep thingies play. perhaps i didnt explain myself well enough before
# This is where we define the dialogue sounds.
def dialoguesound(event, interact=True, **kwargs):
if not interact:
return
if event == "show":
renpy.sound.play("sfx/voices/generic.ogg", channel="dialogue", loop=True)
elif event == "slow_done":
renpy.sound.stop(channel="dialogue", fadeout=0.1)
So, it's generic blips. You just have that as callback for the character and dialogue causes events to be provided.
See if this can help you: https://www.renpy.org/doc/html/character_callbacks.html#character-callbacks
You just need to pay additional attention to "slow_done" and that would be the same as "show_done". Probably like this:
def dialoguesound(event, interact=True, **kwargs):
if not interact or event in ("slow_done", "show_done"):
renpy.sound.stop(channel="dialogue", fadeout=0.1)
elif event == "show":
renpy.sound.play("sfx/voices/generic.ogg", channel="dialogue", loop=True)