I want to do some batch processing on my collection of classic wads (which is in the thousands), and I would like to clarify two points regarding the wad format.
+ Where do maps (ExMy/MAPxx) end?
When I process levels, I generally treat level markers like a folder (as I think is the standard). So if you extract the resources, you end up with a folder with the name of the marker entry, and all of the lumps underneath (things, etc) within that.
As there is no 'end' marker for level data, where does the 'folder' end? The Doom Specs were never clear on it, and I haven't been able to find a definitive answer.
My approach (as demonstrated below) is to treat all recognized level lumps as part of the level folder, and consider the folder ended when a non-level lump is encountered.
name aname date time size crc type offset
-------- -------- ----------- ----- --------- -------- -------- ---------
platform, ,24-feb-1995,11:53, 3562,c14ff6c6,unknown , 2465882
-- UP --
e3m7 ,mudmad14,24-feb-1995,11:53, 72314,6268b650,folder , 2469444
- DOWN -
things , ,24-feb-1995,11:53, 4620,ff573c14,binary , 2469444
linedefs, ,24-feb-1995,11:53, 8596,cbe338be,binary , 2474064
sidedefs, ,24-feb-1995,11:53, 23970,0239668a,binary , 2482660
vertexes, ,24-feb-1995,11:53, 2544,880ee47e,binary , 2506630
segs , ,24-feb-1995,11:53, 10920,c8054ee6,binary , 2509174
ssectors, ,24-feb-1995,11:53, 1280,3e1bdecf,binary , 2520094
nodes , ,24-feb-1995,11:53, 8932,03170841,binary , 2521374
sectors , ,24-feb-1995,11:53, 2210,1d98abe3,binary , 2530306
reject , ,24-feb-1995,11:53, 904,2c9438cc,binary , 2532516
blockmap, ,24-feb-1995,11:53, 6776,28ffe235,binary , 2533420
platform, ,24-feb-1995,11:53, 1370,5957e729,unknown , 2540196
-- UP --
demo1 , ,24-feb-1995,11:53, 34624,9e2d02e3,unknown , 2541566
demo2 , ,24-feb-1995,11:53, 29540,51d1ef79,unknown , 2576190
demo3 , ,24-feb-1995,11:53, 33944,f77efa22,unknown , 2605730
e3m8 ,mudman17,24-feb-1995,11:53, 75551,97623788,folder , 2639674
- DOWN -
things , ,24-feb-1995,11:53, 2100,0a7f8537,binary , 2639674
The problem with this approach is that there are a number of 'custom' lumps around which are attached to levels (like 'platform' in the above). So whatever is reading in the directory needs to be aware of these.
Another possible approach is to end the level when you hit the next level marker (or other marker entry) since they tend to be clustered together. But as the above shows, this would then 'incorrectly' bundle the demo entries under the level.
So what's the consensus from the Doom community? At what point do you consider a lump to not be part of a level?
+ What's the character set for WAD entry names?
It's a given that entries can consist of any alphanumeric name up to 8 characters in length, as well as the underscore, as these are used in original game.
Further, you can add the '[', '/', and ']' characters to the list, as those are used for sprite frames of index 26-28.
What other characters are acceptable in entry names? And if the answer to that is any characters, then what is the general standard?
Also, are entry names case-insensitive? I've always treated them as such, and if it is indeed the case it puts a theoretical limit on the number of frames a sprite can have.
Thanks in advance.