Skip to content

Commit

Permalink
Make the Freedoom IWADs their own mission pack and add support for th…
Browse files Browse the repository at this point in the history
…e freedoom-all autoload directory.
  • Loading branch information
MelodicSpaceship committed Feb 6, 2025
1 parent 09d1399 commit 6d38f02
Show file tree
Hide file tree
Showing 4 changed files with 46 additions and 26 deletions.
9 changes: 9 additions & 0 deletions setup/multiplayer.c
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,12 @@ static const char *rekkr_skills[] =
"Scrapper", "Brawler", "Fighter", "Wrecker", "BERSERKER"
};

static const char *freedoom_skills[] =
{
"Please don't kill me!", "Will this hurt?", "Bring on the pain.",
"Extreme carnage.", "MAYHEM!",
};

static const char *gamemodes[] = { "Co-operative", "Deathmatch",
"Deathmatch 2.0", "Deathmatch 3.0" };

Expand Down Expand Up @@ -292,6 +298,9 @@ static void UpdateSkillButton(void)
case pack_rekkr:
skillbutton->values = rekkr_skills;
break;
case pack_freedoom:
skillbutton->values = freedoom_skills;
break;
default:
skillbutton->values = doom_skills;
break;
Expand Down
36 changes: 18 additions & 18 deletions src/d_iwad.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,26 +28,26 @@
#include "m_misc.h"

static const iwad_t iwads[] = {
{"doom2.wad", doom2, commercial, "DOOM II: Hell on Earth" },
{"plutonia.wad", pack_plut, commercial, "Final DOOM: Plutonia Experiment"},
{"tnt.wad", pack_tnt, commercial, "Final DOOM: TNT - Evilution" },
{"doom2.wad", doom2, commercial, "DOOM II: Hell on Earth" },
{"plutonia.wad", pack_plut, commercial, "Final DOOM: Plutonia Experiment"},
{"tnt.wad", pack_tnt, commercial, "Final DOOM: TNT - Evilution" },
// "doom.wad" may be retail or registered
{"doom.wad", doom, indetermined, "DOOM" },
{"doom.wad", doom, registered, "DOOM Registered" },
{"doom.wad", doom, retail, "The Ultimate DOOM" },
{"doom.wad", doom, indetermined, "DOOM" },
{"doom.wad", doom, registered, "DOOM Registered" },
{"doom.wad", doom, retail, "The Ultimate DOOM" },
// "doomu.wad" alias to allow retail wad to coexist with registered in the same folder
{"doomu.wad", doom, retail, "The Ultimate DOOM" },
{"doom1.wad", doom, shareware, "DOOM Shareware" },
{"doom2f.wad", doom2, commercial, "DOOM II: L'Enfer sur Terre" },
{"freedoom2.wad", doom2, commercial, "Freedoom: Phase 2" },
{"freedoom1.wad", doom, retail, "Freedoom: Phase 1" },
{"freedm.wad", doom2, commercial, "FreeDM" },
{"chex.wad", pack_chex, retail, "Chex Quest" },
{"chex3v.wad", pack_chex3v, retail, "Chex Quest 3: Vanilla Edition" },
{"chex3d2.wad", pack_chex3v, commercial, "Chex Quest 3: Modding Edition" },
{"hacx.wad", pack_hacx, commercial, "HACX: Twitch n' Kill" },
{"rekkrsa.wad", pack_rekkr, retail, "REKKR" },
{"rekkrsl.wad", pack_rekkr, retail, "REKKR: Sunken Land" },
{"doomu.wad", doom, retail, "The Ultimate DOOM" },
{"doom1.wad", doom, shareware, "DOOM Shareware" },
{"doom2f.wad", doom2, commercial, "DOOM II: L'Enfer sur Terre" },
{"freedoom2.wad", pack_freedoom, commercial, "Freedoom: Phase 2" },
{"freedoom1.wad", pack_freedoom, retail, "Freedoom: Phase 1" },
{"freedm.wad", pack_freedoom, commercial, "FreeDM" },
{"chex.wad", pack_chex, retail, "Chex Quest" },
{"chex3v.wad", pack_chex3v, retail, "Chex Quest 3: Vanilla Edition" },
{"chex3d2.wad", pack_chex3v, commercial, "Chex Quest 3: Modding Edition" },
{"hacx.wad", pack_hacx, commercial, "HACX: Twitch n' Kill" },
{"rekkrsa.wad", pack_rekkr, retail, "REKKR" },
{"rekkrsl.wad", pack_rekkr, retail, "REKKR: Sunken Land" },
};

static const char *const gamemode_str[] = {
Expand Down
10 changes: 10 additions & 0 deletions src/d_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -1360,6 +1360,10 @@ static void LoadIWadBase(void)
{
W_AddBaseDir("doom2-all");
}
else if (local_gamemission == pack_freedoom)
{
W_AddBaseDir("freedoom-all");
}
W_AddBaseDir(M_BaseName(wadfiles[0]));
}

Expand Down Expand Up @@ -1397,6 +1401,12 @@ static void AutoloadIWadDir(void (*AutoLoadFunc)(const char *path))
AutoLoadFunc(dir);
free(dir);
}
else if (local_gamemission == pack_freedoom)
{
dir = GetAutoloadDir(autoload_paths[i], "freedoom-all", true);
AutoLoadFunc(dir);
free(dir);
}
}

// auto-loaded files per IWAD
Expand Down
17 changes: 9 additions & 8 deletions src/doomdef.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,14 +33,15 @@ typedef enum {

// Mission packs - might be useful for TC stuff?
typedef enum {
doom, // DOOM 1
doom2, // DOOM 2
pack_tnt, // TNT mission pack
pack_plut, // Plutonia pack
pack_chex, // Chex Quest
pack_hacx, // Hacx
pack_rekkr, // Rekkr
pack_chex3v, // Chex Quest 3: Vanilla Edition
doom, // DOOM 1
doom2, // DOOM 2
pack_tnt, // TNT mission pack
pack_plut, // Plutonia pack
pack_chex, // Chex Quest
pack_hacx, // Hacx
pack_rekkr, // Rekkr
pack_chex3v, // Chex Quest 3: Vanilla Edition
pack_freedoom, // Freedoom
none
} GameMission_t;

Expand Down

0 comments on commit 6d38f02

Please sign in to comment.