So I lost my game to a weird "root element missing" error. The game won't open. I have a backup but it's missing a complex dialog I was just working on. I can see where the room scripts and such are in the the corrupted game's file folders, but I haven't uncovered where the dialogs are hiding yet.
I can redo the dialog but I'd like save a few hours if possible and just copy and paste the dialog into my backup.
If you open game.agf, search for "<Dialogs>" and scroll down you should see all the dialogs.
Thing is that "root element missing" error means that Game.agf is corrupted, so there is high chance the contents are destroyed.
If that's the case, also check Game.agf.bak which is a copy of previous version of Game.agf made at the last save.
So I read about this error and found out it has something to do with the extra character getting added to the start of a file when it is saved with the wrong encoding.
But how can it be fixed? No idea...
QuoteSo I read about this error and found out it has something to do with the extra character getting added to the start of a file when it is saved with the wrong encoding.
But how can it be fixed? No idea...
That should be easy to check if that's so, simply open Game.agf in the text editor that displays encoding and hidden characters (like Notepad++). Also if that's really the case then it would be simple to fix as well by saving in proper encoding. That won't answer the question how it got into wrong one though.