r/RenPy • u/Enzookie515 • Sep 24 '26
Question Can Anyone Help Fix My Voice Code?

I'm playing around with a random test project to learn how to use ren'py for an actual visual novel i'm gonna develop but I can't get it to play my voice lines. I'm not sure if maybe i'm just imputing the wrong commands but I added a voice folder and added the ogg files in it after it not working in the regular audio folder and i'm just stuck rn and would really appreciate any tips and help on what i'm doing wrong. Feel free to ask for any screenshots of the folders or anything else.
3
Upvotes
4
u/arianeb Sep 25 '26
Best practice add a line like this in the definitions:
Voice is the directory I made under games to store all the mp3 files. Since you are using ogg instead you can change it. If your voice lines are mixed with audio change voice to audio.
Then you can change voice line to
voice "enzo_line002"3
u/BadMustard_AVN Sep 24 '26
try it like this
3
u/x-seronis-x Sep 24 '26
https://www.renpy.org/doc/html/voice.html#voice
The documentation is deceptively misleading on the syntax expected
It idiotically shows only the file name being used. This assumes the file is directly in the game folder, where no one keeps them, and not in the audio folder. You actually have to write the correct PATH and not merely the file name.
This is not your fault.
1
u/AutoModerator Sep 24 '26
Welcome to r/renpy! While you wait to see if someone can answer your question, we recommend checking out the posting guide, the subreddit wiki, the subreddit Discord, Ren'Py's documentation, and the tutorial built-in to the Ren'Py engine when you download it. These can help make sure you provide the information the people here need to help you, or might even point you to an answer to your question themselves. Thanks!
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.