Corrupted game.

There was a power outage and now my game is corrupted. I tried replacing the project file, but the json data files are corrupted too.

How can I salvage the game? I can't possibly remember where everything in the database was. This is kinda urgent, I might have to consider cancelling the game I spent months working on.

Any advice?
Mine is to aways use github or google drive to have a backup in a cloud storage.


Usually when you try to start the project RM will tell you which file is damaged and should be replaced.
make a backup of the current project, make a new project, then copy the damaged files from the new project to the backup, checking after each copy.


Hope that not too many files have been destroyed, and see what is still left after the program runs again.


and now you know why everyone with any IT knowledge always drones about


Backup, Backup, Backup - and in case you haven't heard, you need to backup your data....


Sorry, there isn't really much you can do to restore destroyed data, especially if it was destroyed that way...
That's fantastic.

Basically, most of the .json data is destroyed so I'm just gonna stop making the game and give up immediately and forever, like any reasonably person would.

Thanks for the help, problem solved. Thread closed.
Can you open up the JSON files in Notepad (or another text editor)? If you can see plain, normal text (with parenthesis, and so on) then perhaps the problem is elsewhere.
It's pretty much like Andar said.  Though in my experience (with Ace - been lucky enough not to get a corruption in MV yet), it is usually not as dire as it first appears.  Most likely, you will not have to cancel your project because you will be able to recover over 90% of your work.  The best case scenario is that the corruption could be limited to a single map that you will need to remake!  The worst case scenario might be that several large parts of your database became corrupt.


Create a new project, and make a backup copy of each of its folders (for example, make a backup copy of the "js" folder and call it "old js").  Then, start copying folders over from your corrupt project, into your new project, one by one.  Each time you do - save, quit, try to re-open the program, and make sure you don't get the "corrupt" message.  In the case of the "data" folder, where the corruption probably is, you will want to make a backup copy of each clean FILE and copy each file over one by one, instead of the entire folder at once, save-quit-reopening each time you do a single file.  Tedious, but an hour or two of tedium is worth saving months of work.


Whenever you copy something and it does give you the corruption error next time you open, delete that thing and replace it with the clean file or folder that you made the backup copy for (for example, if the "Enemies" file caused the corruption then you should delete it (from the new project, not from your original corrupt project), and rename the "old Enemies" backup file that you made as "Enemies" again), save, quit, re-open, and make sure that there's no corruption anymore.  Note that whatever was in that file will be lost (unless you have a way to copy the text from the json file into a new file, which is still very risky) - so if you were unlucky enough to have your Enemies file corrupted - yep, you're gonna have to remake every Enemy in your game.  But everything else that's not corrupt will be restored!  Oh, and if a folder that you tried copying over was corrupt (unlikely outside the data folder), you can try copying files from that folder over one by one (or a few at a time) instead, after deleting the corrupt folder and restoring the backup version you made of that folder to its original name.


Once you've carried over everything that wasn't corrupted, what you'll have in your new project is a copy of your old project, minus whatever data became corrupt.  You will be able to work with it in the editor and you will be able to playtest and package it just like your old project (although if data is needs is missing, you'll encounter errors until you remake that data - for example, if the game had a warp to a map that is now missing because it's corrupt, you'll need to make sure you remake that map because it won't know where to warp you since the map is now missing).


From now on, I recommend creating a backup version of your entire project (just copy and paste the project folder in Windows Explorer - easy) for every 5-10 hours that you put into your project, so that you can revert to that version without going through this process and losing your work next time this happens.  Trust me - I live in South Florida so I know what power outages do to RPG Maker data!!  And every month or so, be sure to copy that backup version to secure Cloud storage (preferred, because it also means your data is safe from fire, flood, and physical theft) or an external drive (even a $10 zip drive is fine), which will keep your stuff safe in case your hard drive ever fails.

Original thread: https://forums.rpgmakerweb.com/threads/corrupted-game.68315/