|
Thread: Reading HiScore.dat | |
|
Retro
Tavern Dweller
|
posted September 11, 2020 08:47 PM |
|
|
Reading HiScore.dat
Hi All,
I'm working on a HOMM3 utility and want to read the high score file. I can open it in notepad/hex/etc. and read some of the text, but a lot is missing/encoded.
Has anyone worked out a way to read/edit it (or any of the other .dat files)?
____________
|
|
maryKevaa
Tavern Dweller
|
posted September 15, 2020 05:38 AM |
|
|
I'm sorry, I have never used the HOMM3 feature!
____________
[url=https://theimpossiblequiz.online]the impossible quiz[/url]
|
|
Baronus
Legendary Hero
|
posted September 15, 2020 08:55 AM |
|
|
Ofcourse you must use HDeditor eg.HxD. Here all is nice and clear. Especially if you break your name of something like that you can correct.
|
|
tttc
Tavern Dweller
|
posted September 18, 2020 04:36 PM |
|
Edited by tttc at 16:41, 18 Sep 2020.
|
The file keeps track of 11 high scores for the campaign, followed by 11 high scores for single scenarios. Each entry is 0x64 bytes long. The data for each entry is as follows:
Player name (text, offset: 0x00, size: 0x29)
Campaign or map name (text, offset: 0x29, size: 0x2B)
Score (int, offset: 0x54, size: 0x4)
Days (int, offset: 0x58, size: 0x4)
Difficulty (int, offset: 0x5C, size: 0x4)
Unknown / Unused (always 0x00000000, offset: 0x60, size:0x4)
The offsets are relative to the beginning of each entry of course.
Score, days and difficulty are ints. More specifically 4-byte signed integers. The values for difficulty represents the rating, where
80 = Easy
100 = Normal
129 = Hard
160 = Expert
200 = Impossible
Take notice that Hard is 129, and not 130 as one might think. I have no idea why it's like that.
|
|
|
|