Packing into PK3 is not working correctly

Ask about mapping, UDMF, using DoomBuilder/editor of choice, etc, here!

Moderator: GZDoom Developers

Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.
sacarias
Posts: 50
Joined: Wed Oct 02, 2019 9:39 am

Packing into PK3 is not working correctly

Post by sacarias »

If packing like this:
--mapinfo.txt
--graphics
----titlepic.png
--NERVE.WAD
everything works (even all GZDoom core lumps seem to be inherited or the like).

But if packing like:
--mapinfo
----mapinfoNerve.txt
--graphics
----titlepic.png
--maps
----NERVE.WAD (in order to prevent RAM leaking according to the docs)
this is totally broken; neither PWAD nor mapinfo lump are recognized at all.

Why does second way break things?
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49223
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: Packing into PK3 is not working correctly

Post by Graf Zahl »

The second way breaks because it's not how things need to be organized.

First, nothing loads the included MAPINFO so of course its contents are not used.
Second, you need to place single maps into the maps folder, not full WADs. Those also won't get loaded.
sacarias
Posts: 50
Joined: Wed Oct 02, 2019 9:39 am

Re: Packing into PK3 is not working correctly

Post by sacarias »

Then full WADs must never be inside directories? Will there never be a way to avoid "RAM leaking" if putting full WADs inside PK3?
User avatar
SPZ1
Posts: 388
Joined: Wed Aug 02, 2017 3:01 pm
Location: Illinois

Re: Packing into PK3 is not working correctly

Post by SPZ1 »

There is no such thing as "RAM leaking". Your plain text files should be in the root directory. You can put any kind of .WAD in the root as well.
sacarias
Posts: 50
Joined: Wed Oct 02, 2019 9:39 am

Re: Packing into PK3 is not working correctly

Post by sacarias »

1.- RAM leaking/corruption:
https://zdoom.org/wiki/Using_ZIPs_as_WA ... ent#How_to

2.- So the mapinfo directory inside gzdoom.pk3 is actually not a PK3 core lump?
User avatar
SPZ1
Posts: 388
Joined: Wed Aug 02, 2017 3:01 pm
Location: Illinois

Re: Packing into PK3 is not working correctly

Post by SPZ1 »

Just how large is this project you are working on? Mine is currently a bit over 750MB and I've never experienced memory corruption.
sacarias
Posts: 50
Joined: Wed Oct 02, 2019 9:39 am

Re: Packing into PK3 is not working correctly

Post by sacarias »

Then why the info there at wiki?

And, is the mapinfo directory inside gzdoom.pk3 actually not a PK3 core lump, so "nothing loads mapinfo directory"?
User avatar
Enjay
 
 
Posts: 26938
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland

Re: Packing into PK3 is not working correctly

Post by Enjay »

If you look inside game_support.pk3, there is a file called iwadinfo.txt. That has explicit path information for the various supported games and where to find their mapinfo files. I assume that's what tells the game to look in the mapinfo folder, and which file to look at for which game.

e.g.

Code: Select all

// Doom 2 must be last to be checked because MAP01 is its only requirement
IWad
{
	Name = "DOOM 2: Hell on Earth"
	Autoname = "doom.id.doom2.commercial"
	Game = "Doom"
	Config = "Doom"
	IWADName = "doom2.wad", 1
	Mapinfo = "mapinfo/doom2.txt"
	Compatibility = "Shorttex", "nosectionmerge"
	MustContain = "MAP01"
	BannerColors = "a8 00 00", "a8 a8 a8"
	IgnoreTitlePatches = 1
}
sacarias
Posts: 50
Joined: Wed Oct 02, 2019 9:39 am

Re: Packing into PK3 is not working correctly

Post by sacarias »

Thanks, that finally made sense.

Lastly, why the info at that wiki link regarding PK3 and RAM corruption?
User avatar
Redneckerz
Spotlight Team
Posts: 1115
Joined: Mon Nov 25, 2019 8:54 am
Graphics Processor: Intel (Modern GZDoom)

Re: Packing into PK3 is not working correctly

Post by Redneckerz »

sacarias wrote: Sun Apr 07, 2024 1:26 pm Lastly, why the info at that wiki link regarding PK3 and RAM corruption?
Because, like most good Wiki's, it explains a rather obvious flaw when you attempt to do this. The fact that the Wiki documents this means people in the past have tried to do this - with disastrous results. :)
sacarias
Posts: 50
Joined: Wed Oct 02, 2019 9:39 am

Re: Packing into PK3 is not working correctly

Post by sacarias »

Redneckerz wrote: Mon Apr 08, 2024 12:55 pm Because, like most good Wiki's, it explains a rather obvious flaw when you attempt to do this. The fact that the Wiki documents this means people in the past have tried to do this - with disastrous results. :)
Then this would make user SPZ1 a complete fool, and either he has no dignity, or you are the one who doesn't, or this is a witch hunt for free.
Nothing makes sense here
User avatar
phantombeta
Posts: 2160
Joined: Thu May 02, 2013 1:27 am
Operating System Version (Optional): Windows 10
Graphics Processor: nVidia with Vulkan support
Location: Brazil

Re: Packing into PK3 is not working correctly

Post by phantombeta »

sacarias wrote: Mon Apr 08, 2024 1:11 pm Then this would make user SPZ1 a complete fool, and either he has no dignity, or you are the one who doesn't, or this is a witch hunt for free.
Nothing makes sense here
This is needlessly hostile. The wiki is inaccurate about it causing memory corruption, but it's very much correct about it using up more memory (though it's not leaking it- the wiki doesn't claim it is, anyway). GZDoom decompresses the WAD in memory, then loads it as if it were a normal WAD, and to do that, it needs to keep that decompressed copy around in memory, so it's gonna use up memory that it wouldn't have if it were loading from disk.
User avatar
SanyaWaffles
Posts: 840
Joined: Thu Apr 25, 2013 12:21 pm
Preferred Pronouns: They/Them
Operating System Version (Optional): Windows 11 for the Motorola Powerstack II
Graphics Processor: nVidia with Vulkan support
Location: The Corn Fields

Re: Packing into PK3 is not working correctly

Post by SanyaWaffles »

I have to agree with phantombeta here, it seems needlessly hostile.

I'm not 100% sure what you're trying to do as well
User avatar
Hellser
Global Moderator
Posts: 2769
Joined: Sun Jun 25, 2006 4:43 pm
Preferred Pronouns: He/Him
Operating System Version (Optional): Manjaro Linux
Graphics Processor: ATI/AMD with Vulkan/Metal Support
Location: Citadel Station

Re: Packing into PK3 is not working correctly

Post by Hellser »

Just a little heads up: That warning was added in July, 2015. Let's put that into perspective: GZDoom's version was 2.1 (32-bit), ZDoom was a pre-release of 2.8 (32 and x64 versions available). Note the last version of ZDoom is 2.8.1. If memory serves, 32-bit applications could only access up to 4GB (maybe!) of RAM. Also the person who wrote that warning was known for creating one of the largest multiverse thrown together wads that took a little to load even on the fastest of systems. So they were most likely writing from their own personal experience - and everyone took it at face value, because hey! It made sense at the time.

There's no need - and I am going to repeat: there is no need to be hostile to anyone on the forums for following something that they believe to be true from a decade+ of using GZDoom. The wiki is our bible - and all bibles have their faults... and like any text written by mankind, it can be fixed.
User avatar
Redneckerz
Spotlight Team
Posts: 1115
Joined: Mon Nov 25, 2019 8:54 am
Graphics Processor: Intel (Modern GZDoom)

Re: Packing into PK3 is not working correctly

Post by Redneckerz »

sacarias wrote: Mon Apr 08, 2024 1:11 pm
Redneckerz wrote: Mon Apr 08, 2024 12:55 pm Because, like most good Wiki's, it explains a rather obvious flaw when you attempt to do this. The fact that the Wiki documents this means people in the past have tried to do this - with disastrous results. :)
Then this would make user SPZ1 a complete fool, and either he has no dignity, or you are the one who doesn't, or this is a witch hunt for free.
Nothing makes sense here
Good to know i am called as someone with no dignity for giving a mere explanation, aside from flaming another user. :?
Hellser wrote: Tue Apr 09, 2024 1:52 am Just a little heads up: That warning was added in July, 2015. Let's put that into perspective: GZDoom's version was 2.1 (32-bit), ZDoom was a pre-release of 2.8 (32 and x64 versions available). Note the last version of ZDoom is 2.8.1. If memory serves, 32-bit applications could only access up to 4GB (maybe!) of RAM. Also the person who wrote that warning was known for creating one of the largest multiverse thrown together wads that took a little to load even on the fastest of systems. So they were most likely writing from their own personal experience - and everyone took it at face value, because hey! It made sense at the time.
True, 32 bit applications can address up to 4 GB RAM. In practice, due to Windows, its usually 3 GB.

That warning likely needs to rewritten to reflect it came from an period in GZDoom where a lot of refactoring yet had to take place. Nowadays GZDoom coasts most heavy WADS and computers have gone significantly more powerful on top of GZDoom being better suited towards modern machines.

Return to “Mapping”