Corrupt X and H file? |
Tue, 11 May 2021 12:14 |
|
wildcard | | Crewman 2nd Class | Messages: 18
Registered: May 2005 | |
|
Anyone heard of this before? I turned my system off after saving last night (almost finished all my orders but wasn't quite done with the turn yet, no new turn generated), powered it back up this morning and now my .X file is corrupt (all my orders I put in are gone, back to the beginning of the turn) and my .H file is corrupt (no planet history, all planets that I am not actively scanning show as grey dots, as in unexplored).
All the files are physically there with the correct time stamp from my last save.
Any ideas?
Report message to a moderator
|
|
|
|
|
|
|
|
Re: Corrupt X and H file? |
Wed, 12 May 2021 09:30 |
|
wildcard | | Crewman 2nd Class | Messages: 18
Registered: May 2005 | |
|
Yes, this is the conclusion I am coming to, it's probably faster to just re-do the turn. I will check out the TotalHost tools, to see if anything can be done with that. Right now, I am just trying to see if I can recover any of the .X file.
Your suggestion about loading up old turns to rebuild the history helped. Even though I only have 10 turns worth of history, it helped. At first not all of turns had the history "stick". It seemed like I did have to load the turn, make a change, and then save it to get the history to stick. Then load up the next turn.
Considering the sensitivity of these files, and the time some of us sink into these turns, does what sort of backup does everyone use? Seems like the built in turn backup skips the history file.
I have been thinking of scripting something that backs up the directory every 30 minutes (checks for any changes first and skips if no changes). Anyone else do anything like that?
Report message to a moderator
|
|
|
Re: Corrupt X and H file? |
Wed, 12 May 2021 11:15 |
|
ricks03 | | | Messages: 222
Registered: January 2012 Location: NC | |
|
There are a few backup considerations. First, Stars! doesn't generate a .h file at the Host level. So a hosting platform can archive the .x, .xy (which never changes), .m, and .hst file. But the only place the .h file exists is on your local system.
The .x file is not dynamic. It only updates when you select "Save". So any scripting you write will have to include you manually selecting Save on some regular basis. That .x file is then appended to each time you save, which you can see when you "look" at it. If you add something to your queue, then remove it, then add it back, that's three sequential operations in the .x file -- leading to a problem if you do that a LOT, because there's a limited number of orders that can be contained in the .x file. It's a BIG number (32k IIRC); I've only reached it programatically.
It is worth scripting a local copy of each turn tho. Totalhost has the option for a player to download their entire game history precisely so they can recover a (local) lost .h file when they failed to keep a local copy!
The utilities in TH can pretty much tear apart most of the Stars! files, but they're unlikely to output specifically what you're looking for in a ready to use format for manually recreating a .x file, because I didn't really write them for that purpose. They're primarily the foundation for the hosting code that looks for bugs and cheats in the files (like checking to see if someone has submitted a colonizer that exhibits the "free colonizer" bug). I tend to write a utility to search fro something as a standalone, and then integrate it into the hosting code.
https://www.irelandbybicycle.com
http://totalhost.sinister.net:999
https://github.com/ricks03/TotalHostReport message to a moderator
|
|
|
|
|
|
|