GAMEMAPS.XXX on 4.10-stable vs 4.11-dev

Bugs that have been investigated and resolved somehow.

Moderator: GZDoom Developers

Forum rules
Please don't bump threads here if you have a problem - it will often be forgotten about if you do. Instead, make a new thread here.
User avatar
CacoKnight
Posts: 12
Joined: Wed Sep 13, 2023 8:48 pm

GAMEMAPS.XXX on 4.10-stable vs 4.11-dev

Post by CacoKnight »

Hello, just registered and first post here, just wanted to report that GZDoom 4.11-dev gives me "unknown checksum" on those 4 map files (.WL6, .SOD, .SD2, .SD3) when I load Wolf3D.ipk3 but with GZDoom 4.10-stable it's all good and they load perfectly.

Can a dev look into this?

Thank you.
User avatar
wildweasel
Posts: 21706
Joined: Tue Jul 15, 2003 7:33 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): A lot of them
Graphics Processor: Not Listed
Contact:

Re: GAMEMAPS.XXX on 4.10-stable vs 4.11-dev

Post by wildweasel »

Wait, do we have Wolf3D support officially, or is this a downloadable TC?
User avatar
Kappes Buur
 
 
Posts: 4172
Joined: Thu Jul 17, 2003 12:19 am
Graphics Processor: nVidia (Legacy GZDoom)
Location: British Columbia, Canada
Contact:

Re: GAMEMAPS.XXX on 4.10-stable vs 4.11-dev

Post by Kappes Buur »

Loading Wolf3D.ipk3 with
  • gzdoom-x64-g4.11pre-279-g22271d146
  • gzdoom-x64-g4.11pre-355-gf6c3ce6b1
runs without any problem for me.
User avatar
CacoKnight
Posts: 12
Joined: Wed Sep 13, 2023 8:48 pm

Re: GAMEMAPS.XXX on 4.10-stable vs 4.11-dev

Post by CacoKnight »

They all load Wolf3D.ipk3 without issues, the GAMEMAPS.XXX files are the issue. I tried all the builds now and THE LAST WORKING ONE IS build 279.

354, 355, 357, 364 and 372 all give "WARNING: GAMEMAPS.XXX has an unknown hash HASHVALUE".
Last edited by CacoKnight on Thu Sep 14, 2023 5:55 pm, edited 1 time in total.
User avatar
wildweasel
Posts: 21706
Joined: Tue Jul 15, 2003 7:33 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): A lot of them
Graphics Processor: Not Listed
Contact:

Re: GAMEMAPS.XXX on 4.10-stable vs 4.11-dev

Post by wildweasel »

Do you know what version of the game your gamemaps files are from?
User avatar
Rachael
Posts: 13923
Joined: Tue Jan 13, 2004 1:31 pm
Preferred Pronouns: She/Her
Contact:

Re: GAMEMAPS.XXX on 4.10-stable vs 4.11-dev

Post by Rachael »

The Wolf3D.ipk3 project has an old version of 3saster's md5 hashing algorithm. I've tried fixing it on my own but I am not getting the correct result.

Just to clarify, the Wolf3D.ipk3 has scripting code to read the GAMEMAPS.XXX files - GZDoom does not handle this on its own. However, GZDoom did change the ReadLump implementation since 4.8.0 which is why the md5 hashing algorithm is getting bogus results.
User avatar
AFADoomer
Posts: 1341
Joined: Tue Jul 15, 2003 4:18 pm
Contact:

Re: GAMEMAPS.XXX on 4.10-stable vs 4.11-dev

Post by AFADoomer »

This is a recent change... I just updated to current dev build and it's broken, but the previous build I had (from maybe a month ago, at most?) worked fine.

What changed in the ReadLump implementation?
User avatar
CacoKnight
Posts: 12
Joined: Wed Sep 13, 2023 8:48 pm

Re: GAMEMAPS.XXX on 4.10-stable vs 4.11-dev

Post by CacoKnight »

wildweasel wrote:
> Do you know what version of the game your gamemaps files are from?
They are the latest ones, tried from Steam, GOG etc., all have the same hash.

Rachael wrote:
>Just to clarify, the Wolf3D.ipk3 has scripting code to read the GAMEMAPS.XXX files - GZDoom does not handle this on its own. However, GZDoom did change the ReadLump implementation since 4.8.0 which is why the md5 hashing algorithm is getting bogus results.
It actually does, or does now, read my post again, something changed between build 279 and build 354 that makes GZDoom not load those mapfiles for Wolf3D TC.
User avatar
Rachael
Posts: 13923
Joined: Tue Jan 13, 2004 1:31 pm
Preferred Pronouns: She/Her
Contact:

Re: GAMEMAPS.XXX on 4.10-stable vs 4.11-dev

Post by Rachael »

CacoKnight wrote: Thu Sep 14, 2023 5:57 pm Rachael wrote:
>Just to clarify, the Wolf3D.ipk3 has scripting code to read the GAMEMAPS.XXX files - GZDoom does not handle this on its own. However, GZDoom did change the ReadLump implementation since 4.8.0 which is why the md5 hashing algorithm is getting bogus results.
It actually does, or does now, read my post again, something changed between build 279 and build 354 that makes GZDoom not load those mapfiles for Wolf3D TC.
No, it does not. The Wolf3D.ipk3 is what's handling it. GZDoom does not have code to handle the maps on its own.
User avatar
Rachael
Posts: 13923
Joined: Tue Jan 13, 2004 1:31 pm
Preferred Pronouns: She/Her
Contact:

Re: GAMEMAPS.XXX on 4.10-stable vs 4.11-dev

Post by Rachael »

AFADoomer wrote: Thu Sep 14, 2023 5:25 pm This is a recent change... I just updated to current dev build and it's broken, but the previous build I had (from maybe a month ago, at most?) worked fine.

What changed in the ReadLump implementation?
I don't know, but it's obvious this is a bug, so I've moved this to the bugs section and marking it as critical since I think this needs to be addressed before the next release.
User avatar
CacoKnight
Posts: 12
Joined: Wed Sep 13, 2023 8:48 pm

Re: GAMEMAPS.XXX on 4.10-stable vs 4.11-dev

Post by CacoKnight »

Rachael wrote: Fri Sep 15, 2023 1:59 am No, it does not. The Wolf3D.ipk3 is what's handling it. GZDoom does not have code to handle the maps on its own.
Oh I see, I'm sure there are other things in the code I don't understand. Thanks for taking the time to check it out and test it.
User avatar
AFADoomer
Posts: 1341
Joined: Tue Jul 15, 2003 4:18 pm
Contact:

Re: GAMEMAPS.XXX on 4.10-stable vs 4.11-dev

Post by AFADoomer »

What seems to be happening is that the something underlying the ReadLump call stops parsing the lump when it hits a null character (or maybe there's an error in truncation somewhere?).

If I console.printf the read-in contents of the GAMEMAPS files in older versions, I get the full contents. Now I just get the header and a few characters, then nothing past the first 10-13 bytes... always terminating where there's a 0x00 character in the file.

EDIT: Demo file attached. Reads a simple text file that has a null character at the beginning of the second line. Only prints the first line (first 13 bytes) in current builds, and prints all three lines (66 bytes) in older builds.
Attachments
fileread.pk3
Just load a map.
(942 Bytes) Downloaded 56 times
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49225
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: GAMEMAPS.XXX on 4.10-stable vs 4.11-dev

Post by Graf Zahl »

That last post finally gave me something to analyze it.

Next time, please post your bug report in a way that people not familiar with the mod you are having problems with can UNDERSTAND!

The cause here was a change I made to handle broken shader files ending with a 0-byte but I missed that the function doing the truncation was also used for reading lumps into strings for ZScript.
User avatar
AFADoomer
Posts: 1341
Joined: Tue Jul 15, 2003 4:18 pm
Contact:

Re: GAMEMAPS.XXX on 4.10-stable vs 4.11-dev

Post by AFADoomer »

Thanks, Graf! I can confirm that this is *mostly* fixed - except that ReadLump formerly added a null character at the end of the string, and this change does not.

3saster's MD5 hashing script truncates the last read-in letter by default, so this change isn't fully backward compatible with any mod that used that resource, or otherwise expects a null character at the end of the string.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49225
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: GAMEMAPS.XXX on 4.10-stable vs 4.11-dev

Post by Graf Zahl »

That last 0 byte should never have been there, it was just a side effect of a very weird way to handle this data in the engine. If you read a lump you want the lump's data, not something that appends another byte of data.
Post Reply

Return to “Closed Bugs [GZDoom]”