Chaosforge Forum

DoomRL => Bug Reports => Topic started by: 007bistromath on June 02, 2008, 13:52

Title: Scores Missing
Post by: 007bistromath on June 02, 2008, 13:52
I noticed yesterday that my highscore and player file are missing my first two HMP games. This is odd since, after I played them, I remember looking at them in the highscore table. Something must be overwriting the .dats. Here is my player.dat and score.dat, as well as the post mortems of the two missing games, which are intact.
Title: Re: Scores Missing
Post by: 007bistromath on June 15, 2008, 01:16
This time it ate an AoP win. Now I can't play Pacifism anymore. I never got a chance to try 100. This is extremely annoying. I would literally rather put the stuff back in there with a hex editor, and I am in fact attempting to do that right now. I've had enough of this.
Title: Re: Scores Missing
Post by: Blade on June 15, 2008, 02:42
I can offer my player.dat.
Title: Re: Scores Missing
Post by: 007bistromath on June 15, 2008, 03:01
Thanks man, but I really don't want to lose my stat tracking. I'm proud of some of this stuff. I mainly don't want to play Purity again. It was boring.
Title: Re: Scores Missing
Post by: 007bistromath on June 15, 2008, 04:35
Update: as a result of trying the highscore sorting, which I hadn't even realized existed until just now, I have determined that the problem is not that the information isn't being written, but that the .dats are in fact becoming corrupted somehow. All the lists other than my main one contained serious errors similar to those introduced when I changed values within the .dat by hand. In addition to garbage, pieces of legitimate data appeared out of place. As a result, I realized that the majority of both .dats is dedicated to telling the program where to look instead of the information itself. I could not, in fact, find where the data is stored among all the formatting info.

Why'd you do it this way, Kornel? Having a running total stored in the same place as directions for reading it always results in corruption eventually. Is there any particular reason you couldn't hardcode the table format into the game and just put the info in the .dats?

Sometimes I really wish I had the source for this sucker. ;_;
Title: Re: Scores Missing
Post by: Kornel Kisielewicz on June 15, 2008, 11:21
Actually both dats are encrypted and checksummed, so any change in values by hand will break them.
Title: Re: Scores Missing
Post by: 007bistromath on June 15, 2008, 12:52
...You did encrypt them.

Why did you encrypt them? This seems like much more effort than it's worth to keep somebody from faking something that ultimately doesn't matter. x_x
Title: Re: Scores Missing
Post by: Stossel on July 11, 2008, 14:59
Hi,

Just started playing DoomRL and it's a lot of fun, however I have this same problem and I didn't edit any files.  I have an AoMr game which should enable me to be Sergeant Rank but the high score list doesn't show the game nor is it recognized by my player file even though I saw the game up on the high score list previously.  I have the mortem file still in the folder as well.

Title: Re: Scores Missing
Post by: KiloByte on July 11, 2008, 16:17
Well, did you quit the game afterwards, or killed it (by closing the window, etc)?

Your accomplishments get saved only on quit...
Title: Re: Scores Missing
Post by: Stossel on July 11, 2008, 19:51
Why would (or should) that matter?  The game was already finished and I viewed my high score on the list afterwards.  The mortem is sitting in the folder just like any other game. 

If that's the case, some kind of warning that closing a window isn't the same as "Quit" I would suggest needs to be documented or a lot more visible. 
Title: Re: Scores Missing
Post by: Floyd on July 20, 2008, 04:52
Well, did you quit the game afterwards, or killed it (by closing the window, etc)?

Your accomplishments get saved only on quit...

KiloByte is right. I had a nasty habit of "killing" the game from the window. Now I close it from the startmenu every time. I'm missing my almost succesful AoB matches :(
Title: Re: Scores Missing
Post by: JysusCryst on June 15, 2009, 06:37
NOOOOO!!!!

I just lost my first and (so far) only win!
So not fair!
I'm gonna cry...

Is there any way to reload the stats to get it back, or are we all just SOL?

Also:
If that's the case, some kind of warning that closing a window isn't the same as "Quit" I would suggest needs to be documented or a lot more visible. 

I agree with this. Would it be to difficult to put a "Are you sure you want to exit? Your highscores will not be saved this way. Please choose "Quit" from the main menu." message when you click the close button??? Or perhaps fixing it so it saves even when 'killing' the window? I'm playing 0.9.8.10. Hopefully it'll get fixed by 0.9.9 or 1.0.0.

*sigh*

Back to regaining my stats...
Title: Re: Scores Missing
Post by: Vestin on June 15, 2009, 08:00
Would it be to difficult to put a "Are you sure you want to exit? Your highscores will not be saved this way. Please choose "Quit" from the main menu." message when you click the close button???
That would be pretty pointless, as most people click "yes" on such boxes automatically ;).
Also - I was pretty certain that Windows used to pop a warning of its own when you were trying to close an app which was "still running"...

Or perhaps fixing it so it saves even when 'killing' the window? I'm playing 0.9.8.10. Hopefully it'll get fixed by 0.9.9 or 1.0.0.
The only thing to "fix" here are bad habits. You DON'T kill console applications by hitting the "X" - you make them close themselves.

You can hide the mouse while playing... or play fullscreen... or simply ponder your loss every time you do such a thing. Either way - you'll learn.
Don't get me wrong - I see a difference between bad UI and bad habits. Then again - it's pointless to write the info to the hard drive ALL THE TIME. It's slow and uses up the drive's durability. That's why the data is (or at least - should be) read once, then resides only in memory and is saved when you don't want to play anymore - when you QUIT. Clicking the "X" is outside of the program itself - it's almost like you'd kill it by the task manager - data loss guaranteed. Do you save a Word document before hitting the "X" ? I don't if there even IS an autosave - it's common sense to SAVE before you leave.
Title: Re: Scores Missing
Post by: JysusCryst on June 15, 2009, 08:43
That would be pretty pointless, as most people click "yes" on such boxes automatically ;).

Am I considered a freak because I actually read those messages before clicking?

And trust me, I'm gonna fix this bad habit. I'm using the main menu from now on. Still, a warning before I lost all that info would have been nice.

*sigh*
Title: Re: Scores Missing
Post by: Kornel Kisielewicz on June 15, 2009, 09:43
If I would find a way to intercept the closure in FreePascal before kill that'd be real nice :/
Title: Re: Scores Missing
Post by: Vestin on June 15, 2009, 13:08
If I would find a way to intercept the closure in FreePascal before kill that'd be real nice :/
AFAIK - you can't. It's above the program level. The best you can do is make the game save to disk EVERY TIME the highscores are shown... which would be anoying and unhealthy for the hard drive in the long run.

Still, a warning before I lost all that info would have been nice.
Nah. Like I said - even if it IS possible to implement - it would take some serious rewrite of the whole game.
We could just put the info somewhere where the player would see it... Like the "You are running DoomRL for the first time" screen, the screen after that, the menu... or even the manual.
Title: Re: Scores Missing
Post by: Generic on June 15, 2009, 17:06
[/constructive posts]
Would it be to difficult to put a "Are you sure you want to exit? Your highscores will not be saved this way. Please choose "Quit" from the main menu." message when you click the close button???
That would be pretty pointless, as most people click "yes" on such boxes automatically ;).
Also - I was pretty certain that Windows used to pop a warning of its own when you were trying to close an app which was "still running"...
Gnome's terminal does. Linux wins again! :P
[constructive posts]
Title: Re: Scores Missing
Post by: JysusCryst on June 16, 2009, 05:32
We could just put the info somewhere where the player would see it... Like the "You are running DoomRL for the first time" screen, the screen after that, the menu... or even the manual.

Yeah, that's what I was thinking anyway. Guess I should have specified "warning." :/ The "first time running" and the "version/special thanks" screen would be great. It would save a lot of RAGE.