Page 1 of 1

[Solved] Corrupted script/Long line of NUL

Posted: Fri Apr 14, 2017 3:31 pm
by ButterflyLatte
I'm not sure how it happened, and I am desperately hoping this can be resolved, because otherwise I'll have several thousand words to re-script...

Somehow my script files for corrupted, and opening them in editra gives me a long line of NUL (white text over black boxes). Attempting to launch the game/check for errors gives an error message.

I have heard that it's possible to get an automatic back-up, or save most of it, but I have no idea how. Can someone help me?
The renpy version I use is 6.99.11

Re: Corrupted script/Long line of NUL

Posted: Fri Apr 14, 2017 4:20 pm
by Donmai
What's your operational system? In MacOS you should go to library/RenPy. In Windows you should go to appData/Roaming/RenPy. Look for the backups folder there.

Re: Corrupted script/Long line of NUL

Posted: Fri Apr 14, 2017 4:39 pm
by ButterflyLatte
It looks like my operating system is Windows 8.1

Re: Corrupted script/Long line of NUL

Posted: Fri Apr 14, 2017 6:49 pm
by korova
Did you open the .rpy files or the .rpyc ?

I nearly had a heart attack when I opened a .rpyc file by mistake, I thought all my hard work disappeared befor I realized my original file was stille there, untouched.

Re: Corrupted script/Long line of NUL

Posted: Fri Apr 14, 2017 9:19 pm
by Donmai
ButterflyLatte wrote:It looks like my operating system is Windows 8.1
On your keyboard, press the windows key+r. On the prompt type

Code: Select all

%APPDATA%/RenPy/
and press enter. A directory should open. Look for a folder named backups. You should find copies of your recent works there.

Re: Corrupted script/Long line of NUL

Posted: Sat Apr 15, 2017 12:11 am
by ButterflyLatte
Opening the backups in editra gives me a lot of gibberish and text symbols. Do I need to open it in another program first?

EDIT: I know it can't be due to the script being corrupted because I tried opening a non-corrupted script file's backup and still got gibberish, so I think I missed a step somewhere.

Re: Corrupted script/Long line of NUL

Posted: Sat Apr 15, 2017 2:30 pm
by Donmai
Oops. If the backups folder didn't worked for you then I don't know what to do. If it was a read/write error you should also check your disks for errors. That wouldn't give your files back, but will prevent the same problem to keep happening.

I only stopped having problems with Editra when I quit using it and returned to jEdit.

Please notice that "a lot of gibberish and text symbols" can mean that, as korova suggested, you may have tried to open a rpyc file in your text editor. Only rpy files are human readable.

Re: Corrupted script/Long line of NUL

Posted: Sat Apr 15, 2017 9:19 pm
by ButterflyLatte
Well, that's what's confusing me. I double-checked by opening a backup of a script I have no trouble with, and it looks the same - a bunch of weird symbols.

The files are listed as "SAVE files," so i can't tell if they're rpyc or not. If they are rpyc, I'm not sure what to open them with.

Re: Corrupted script/Long line of NUL

Posted: Sat Apr 15, 2017 11:39 pm
by Donmai
.save files are another thing. They are generated each time a game is run, or when you save a game position.

It seems you're still looking in the wrong place. When I say backups folder, I really mean a folder named backups, that's inside the appdata/Renpy folder. Open that folder, then the subfolder which has the same name of your project.
Your rpy files should be there.

Re: Corrupted script/Long line of NUL

Posted: Sun Apr 16, 2017 12:19 am
by ButterflyLatte
Ah, there it all is!

Thanks a lot, Donmai, I was getting worried for a bit!

Re: [Solved] Corrupted script/Long line of NUL

Posted: Sun Apr 16, 2017 12:40 am
by Donmai
Yay! Glad to know you found it.