Corrupted files
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
- Evildumdum
- Regular
- Posts: 191
- Joined: Sun Jan 18, 2015 8:49 am
- Projects: ApoclypseZ
- Contact:
Corrupted files
So it seems like my files have been corrupted. I have two main files at the moment. Script and map move. When i load up script, i get a message that declares i have an error in my editra. When i try to open the map_move file it seems to have wiped all the data inside it. Some 5000 lines of code now only read NUL NUL NUL NUL NUL NUL. Is there any way of recovering this? Sadly i had just finished up a marathon session and had not had a chance to back up my work when this happened.
It also shows a padlock next to the filename on the files tab when opened if this helps at all.
EDIT* After looking at the corrupted file more closely, in the bottom right hand corner of the open file it has some things that are different to normal files. Where a normal document says ren'py | utf-8 | LF this one says renpy | binary | CRLF. I've tried changing them to the utf8 and LF but it doesn't seem to change anything.
It also shows a padlock next to the filename on the files tab when opened if this helps at all.
EDIT* After looking at the corrupted file more closely, in the bottom right hand corner of the open file it has some things that are different to normal files. Where a normal document says ren'py | utf-8 | LF this one says renpy | binary | CRLF. I've tried changing them to the utf8 and LF but it doesn't seem to change anything.
"If at first you don't succeed, try hitting it with a shoe."
Re: Corrupted files
You can usually recover them from .rpyc and Ren'Py now should have a kick@ass automatic backup system. I am not going to give you advice on it because never having to use it myself (I have Dropbox + Git dual backup system) but I can offer you a bit of advice to not take any action until PyTom (or someone with experience in that area) can tell you where the backups are and how to recover them 
You files may not even be corrupted, I haven't heard anything decent about editra lately so it may be the editor...
===>>
Edit:
This is what I meant, just don't delete the backup folder somehow, copy it elsewhere or something before getting the files:
https://github.com/renpy/renpy/commit/c ... 3afadb0737
You files may not even be corrupted, I haven't heard anything decent about editra lately so it may be the editor...
===>>
Edit:
This is what I meant, just don't delete the backup folder somehow, copy it elsewhere or something before getting the files:
https://github.com/renpy/renpy/commit/c ... 3afadb0737
- Evildumdum
- Regular
- Posts: 191
- Joined: Sun Jan 18, 2015 8:49 am
- Projects: ApoclypseZ
- Contact:
Re: Corrupted files
I've created a copy of all the files, i discovered the backup function. It wont help me this time since it needed to be switched on, but it will next time. As for the file, Im beginning to think it isn't corrupted and has simply been converted to a different encoding method (namely binary). The only problem is that i have no idea how to recover it from that state. I'll upload the file and the .rpyc file to this thread and see if anyone can make any sense of it.
https://mega.nz/#!yV8lBa4Y!uL-SexGoMF23 ... Jdlf558RDU - The problematic file
https://mega.nz/#!CE03gQ7L!bv66CLPxy_9G ... 7O-JYxfA3U - The .rpyc file to go with it
https://mega.nz/#!yV8lBa4Y!uL-SexGoMF23 ... Jdlf558RDU - The problematic file
https://mega.nz/#!CE03gQ7L!bv66CLPxy_9G ... 7O-JYxfA3U - The .rpyc file to go with it
"If at first you don't succeed, try hitting it with a shoe."
- PyTom
- Ren'Py Creator
- Posts: 15893
- Joined: Mon Feb 02, 2004 10:58 am
- Completed: Moonlight Walks
- Projects: Ren'Py
- IRC Nick: renpytom
- Github: renpytom
- itch: renpytom
- Location: Kings Park, NY
- Contact:
Re: Corrupted files
The backup system has been on by default for the past couple of version of Ren'Py. What version are you running?
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom(When was the last time you backed up your game?)
"Silly and fun things are important." - Elon Musk
Software > Drama • https://www.patreon.com/renpytom
- Evildumdum
- Regular
- Posts: 191
- Joined: Sun Jan 18, 2015 8:49 am
- Projects: ApoclypseZ
- Contact:
Re: Corrupted files
it was origionally on 6.99.7, though i've just installed 6.99.8 seperately to see if it worked any better in there. Looking at the backup, it didnt have a save path and the box to turn it on was unchecked. I'd assume i was using a version that didn't have it on by default.
"If at first you don't succeed, try hitting it with a shoe."
Re: Corrupted files
I didn't even know there was a box to check for it... but 6.99.7 sounds recent. If backups are there, they should be in the dir nowhere near Ren'Py, mine are in:
C:\Users\username\AppData\Roaming\RenPy\backups
It will be in between all the project folders (containing save files).
C:\Users\username\AppData\Roaming\RenPy\backups
It will be in between all the project folders (containing save files).
- Evildumdum
- Regular
- Posts: 191
- Joined: Sun Jan 18, 2015 8:49 am
- Projects: ApoclypseZ
- Contact:
Re: Corrupted files
I actually love you right now. I've lost everything i did over the last three days, but it could have been worse. Much much worse. I'd still like to find out if its possible to un-binary the old file, but i can survive without wanting to hang myself with this.
"If at first you don't succeed, try hitting it with a shoe."
- PyTom
- Ren'Py Creator
- Posts: 15893
- Joined: Mon Feb 02, 2004 10:58 am
- Completed: Moonlight Walks
- Projects: Ren'Py
- IRC Nick: renpytom
- Github: renpytom
- itch: renpytom
- Location: Kings Park, NY
- Contact:
Re: Corrupted files
Evildumdum look for other copies of the file in there. Ren'Py should save each version when it changes, so you'll have a backup of the last copy you've run.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom(When was the last time you backed up your game?)
"Silly and fun things are important." - Elon Musk
Software > Drama • https://www.patreon.com/renpytom
- Evildumdum
- Regular
- Posts: 191
- Joined: Sun Jan 18, 2015 8:49 am
- Projects: ApoclypseZ
- Contact:
Re: Corrupted files
The last copy in the backups was from 02/01/2016
I've done quite alot since then and saved pretty much every five minutes or so. Does it backup when you save the file or close it and re-open it? If its close and re-open then that does make sense. Not that i'm any less grateful. It still rescued two weeks of work.
I've done quite alot since then and saved pretty much every five minutes or so. Does it backup when you save the file or close it and re-open it? If its close and re-open then that does make sense. Not that i'm any less grateful. It still rescued two weeks of work.
"If at first you don't succeed, try hitting it with a shoe."
Re: Corrupted files
I'd imagine that only the editor can do it this way, logically, Ren'Py should be able to it as you force recompile the code or start the game with the new code (which does that automatically). Unless you've ran the game with the new codebit, bytecode file is useless as well. If you have, there should be a more recent backup?Evildumdum wrote:Does it backup when you save the file or close it and re-open it?
(logic may not work for me here btw, Ren'Py often somehow knows when I save a recent file and very conveniently restarts itself to show me the changes, I never actually looked into how the heck does it do that
- Evildumdum
- Regular
- Posts: 191
- Joined: Sun Jan 18, 2015 8:49 am
- Projects: ApoclypseZ
- Contact:
Re: Corrupted files
Makes sense. I hadn't launched the game for a few days. I'm still wondering why the file decided to randomly re-format itself to binary. Is that something that happens occasionally when a file is closed suddenly? Basically my computer auto-shutdown for an update while i was out the room eating. The project was open as it happened. Hate the damn updates on this thing.
"If at first you don't succeed, try hitting it with a shoe."
Re: Corrupted files
Bytecode "decompile" will be useless then. I don't think there was any "re-formatting" involved, it's not something OS just randomly does. As you said, file is prolly plainly corrupted.
- Evildumdum
- Regular
- Posts: 191
- Joined: Sun Jan 18, 2015 8:49 am
- Projects: ApoclypseZ
- Contact:
Re: Corrupted files
Ah well, i know what im doing now so re-doing what i lost shouldn't take anywhere near as long this time. Thankyou for all your patient help on this. You saved me weeks of re-working.
"If at first you don't succeed, try hitting it with a shoe."
-
pandadeath
- Newbie
- Posts: 8
- Joined: Mon May 09, 2016 3:04 pm
- Contact:
Re: Corrupted files
Hello,
I know no one has been on here for some time but my script file became corrupted the same way. I am so sorry that I am dumb, but I can not find the back ups anywhere. I am running windows ten and renpy 6..9.10
If there is anyway I could get help I appreciate it. Otherwise, I do know that it is my own fault and sorry for bothering anyone. Thanks.
I know no one has been on here for some time but my script file became corrupted the same way. I am so sorry that I am dumb, but I can not find the back ups anywhere. I am running windows ten and renpy 6..9.10
If there is anyway I could get help I appreciate it. Otherwise, I do know that it is my own fault and sorry for bothering anyone. Thanks.
- DragoonHP
- Miko-Class Veteran
- Posts: 758
- Joined: Tue Jun 22, 2010 12:54 am
- Completed: Christmas
- IRC Nick: DragoonHP
- Location: Zion Island, Solario
- Contact:
Re: Corrupted files
Well lucky for, Ren'Py automatically backs source files. Look under %appdata%\RenPy\backups
Who is online
Users browsing this forum: Hojoo

