fabiangreffrath / woof

Woof! is a continuation of the Boom/MBF bloodline of Doom source ports.
GNU General Public License v2.0
213 stars 36 forks source link

Woof! recognize as shareware version of doom any iwad named "doom1.wad" #709

Closed fraansg closed 1 year ago

fraansg commented 2 years ago

I have the two versions of Doom, the registered version [1.9, named "doom1.wad"] and the Ultimate version [named "doom.wad"].

When I try to play the registered version (named "doom1.wad") with a patch file, Woof! call a error: "You cannot -file with the shareware version. Register!". This problem doesn't occur in MBF.

The same problem occur with any iwad that I rename to "doom1.wad", but if I rename the registered version to "doom.wad", Woof! recognize that as such.

I know it's not a vital bug, but i wanted to report it.

Pedro-Beirao commented 2 years ago

Isnt the shareware version missings some sprites, music, textures, etc?

If so, it should not be treated the same as the registered one.

Many pwads that you try to load with it might be broken due to the missing lumps.

fraansg commented 2 years ago

Isnt the shareware version missings some sprites, music, textures, etc?

If so, it should not be treated the same as the registered one.

Many pwads that you try to load with it might be broken due to the missing lumps.

The problem is that Woof! treats the registered version as shareware if the iwad is named "doom1.wad"

fabiangreffrath commented 2 years ago

doom1.wad is the canonical file name for the Doom Shareware IWAD: https://doomwiki.org/wiki/DOOM1.WAD

Woof! first tries to determine the gamemode from the IWAD file name and only dives into the file and counts lumps if its name is ambiguous (but in this case, it actually isn't): https://github.com/fabiangreffrath/woof/blob/d51fdc9fb2b01c65730b42940390e67bb163784c/src/d_main.c#L1000 Granted, this is a simplification and generalization inherited from Chocolate Doom that was handled differently back then in MBF.

However, the issue may get resolved if you rename your IWAD file to literally anything but doom1.wad. How about doom_1.wad?

fraansg commented 2 years ago

thanks for the explanation!

fabiangreffrath commented 2 years ago

This would be a possible technical solution, btw:

--- a/src/d_iwad.c
+++ b/src/d_iwad.c
@@ -31,7 +31,7 @@ static const iwad_t iwads[] =
     { "tnt.wad",       pack_tnt,   commercial,   "Final Doom: TNT: Evilution" },
     // "doom.wad" may be retail or registered
     { "doom.wad",      doom,       indetermined, "Doom" },
-    { "doom1.wad",     doom,       shareware,    "Doom Shareware" },
+    { "doom1.wad",     doom,       indetermined, "Doom Shareware" },
     { "doom2f.wad",    doom2,      commercial,   "Doom II: L'Enfer sur Terre" },
     { "chex.wad",      pack_chex,  retail,       "Chex Quest" },
     { "hacx.wad",      pack_hacx,  commercial,   "Hacx" },
Yuraconst commented 1 year ago

you still CAN load patches via Autoload/Doom1.wad folder Even over the real shareware You can load the FreeDoom conversion kit and the Doom1 patch, then any Episode 1 replacement WAD will work, even if it uses assets not in shareware.

fabiangreffrath commented 1 year ago

Not sure what you mean by the "FreeDoom conversion kit", but the entire point of the Freedoom project is to provide free replacements for the commercially available official IWADs.

However, it's a bug that autoloading is allowed for the Shareware gamemode and I have just fixed that. Also, I have taken measures that an IWAD called doom1.wad is not blindly mistaken for the Shareware episode but always gets its contents checked. Thanks for reminding me of this.