Ren'Py newbie here, music/soudn problem with renpy code

rokit6/Naxoll

Member
Mar 30, 2019
215
203
Okay.

Firstly. Never delete .rpyc unless you are also deliberately deleting the .rpy.

The RPYC file is what RenPy actually runs. It contains a very complex cross reference of each line of code in your script. Each line is "numbered" according to previous versions of your code. If you delete the RPYC file, everything is renumbered and so the next time the script runs, it loses all its known reference points. Save files no longer match the structure of the new version of the RPYC file.

Thankfully old copies of an RPYC file can repair things. But any "new" code (when compared with the old RPYC file) will be renumbered. So newer saves may not work

By renaming RPY files, it creates a new RPYC file to match. So you potentially have 2+ copies of the same code. RenPy allows this and has rules about which copy to run.

One potential reason for your play error MIGHT be that you're running a broken version of the code from a "wrong" RPYC file.

Try changing some text near that line and see if you see that update when that line is displayed. If not, you may have a mismatching RPYC file hanging around.
It's rare. But only because most devs never rename RPY files.
You mean try to change the dialog of a character for example? to see if the rpyc is ok?

if that's what you mean, yes, it does change the dialog if I change the text in .rpy
 

AzureSheep

Newbie
Nov 5, 2017
73
1,722
Alright, 79flavors is right and I messed up by suggesting deleting the .rpyc files because I wasn't accounting for the save data.

Just change the name of the .rpy and .rpyc files to something like this

dopus_2022-04-18_18-32-05.png

I have also included the original .rpyc from the dev's release in case yours got messed up. If you add music to the .rpy, it should play properly now and previous save files should work.
 
  • Red Heart
Reactions: rokit6/Naxoll

rokit6/Naxoll

Member
Mar 30, 2019
215
203
Alright, 79flavors is right and I messed up by suggesting deleting the .rpyc files because I wasn't accounting for the save data.

Just change the name of the .rpy and .rpyc files to something like this

View attachment 1764570

I have also included the original .rpyc from the dev's release in case yours got messed up. If you add music to the .rpy, it should play properly now and previous save files should work.
It worked!!!!!! <3 <3 <3

Thanks u so much, you're my savior <3