Sanitize autoloading
Moderator: GZDoom Developers
Sanitize autoloading
I have to admit that right now I'm completely lost about what the autoload sections need to be named. If you ask me it's a complete mess.
Since none of this has been released yet offocially I think there is still time to bring back some sanity and define a hierarchial system like this:
{game}.{subgame}.{iwadname}.autoload
where each of the sublabels can be omitted in which case it would apply to all IWADs which define the present labels.
Under such a scheme all of the present IWADS would be named as follows:
square.full: "The Adventures of Square"
square.squareware: "The Adventures of Square (Square-ware)"
harmony: "Harmony"
hacx.2_0: "Hacx 2.0"
hacx.1_2: "Hacx: Twitch'n Kill"
urbanbrawl: "Action Doom 2: Urban Brawl"
chex.chex3: "Chex(R) Quest 3"
chex.chex: "Chex(R) Quest"
strife: "Strife: Quest for the Sigil"
hexen.hexen: "Hexen: Beyond Heretic"
hexen.deathkings: "Hexen: Deathkings of the Dark Citadel"
blasphemer: "Blasphemer"
heretic.shadow: "Heretic: Shadow of the Serpent Riders"
heretic.heretic: "Heretic (regular)"
doom.freedoom.freedm: "FreeDM"
doom.freedoom.phase2: "Freedoom: Phase 2"
doom.freedoom.phase1: "Freedoom: Phase 1"
doom.freedoom.demo: "Freedoom 'Demo'"
doom.doom1.bfg: "DOOM 1: BFG Edition"
doom.doom1.ultimate: "The Ultimate DOOM"
doom.doom1.registered: "Doom Registered"
doom.doom2.tnt: "Final Doom: TNT - Evilution"
doom.doom2.plutonia: "Final Doom: Plutonia Experiment"
doom.doom2.bfg: "DOOM 2: BFG Edition"
doom.doom2.commercial: "DOOM 2: Hell on Earth"
I think that would bring back some sanity.
As it is now it will be an endless cause of problems for many users who fail to comprehend all the names and relationships. This would also make the definitions in iwadinfo.txt easier to read because there'd only be one string defining autoloading, not a complex relation ship of game, config, group and autoname.
Since none of this has been released yet offocially I think there is still time to bring back some sanity and define a hierarchial system like this:
{game}.{subgame}.{iwadname}.autoload
where each of the sublabels can be omitted in which case it would apply to all IWADs which define the present labels.
Under such a scheme all of the present IWADS would be named as follows:
square.full: "The Adventures of Square"
square.squareware: "The Adventures of Square (Square-ware)"
harmony: "Harmony"
hacx.2_0: "Hacx 2.0"
hacx.1_2: "Hacx: Twitch'n Kill"
urbanbrawl: "Action Doom 2: Urban Brawl"
chex.chex3: "Chex(R) Quest 3"
chex.chex: "Chex(R) Quest"
strife: "Strife: Quest for the Sigil"
hexen.hexen: "Hexen: Beyond Heretic"
hexen.deathkings: "Hexen: Deathkings of the Dark Citadel"
blasphemer: "Blasphemer"
heretic.shadow: "Heretic: Shadow of the Serpent Riders"
heretic.heretic: "Heretic (regular)"
doom.freedoom.freedm: "FreeDM"
doom.freedoom.phase2: "Freedoom: Phase 2"
doom.freedoom.phase1: "Freedoom: Phase 1"
doom.freedoom.demo: "Freedoom 'Demo'"
doom.doom1.bfg: "DOOM 1: BFG Edition"
doom.doom1.ultimate: "The Ultimate DOOM"
doom.doom1.registered: "Doom Registered"
doom.doom2.tnt: "Final Doom: TNT - Evilution"
doom.doom2.plutonia: "Final Doom: Plutonia Experiment"
doom.doom2.bfg: "DOOM 2: BFG Edition"
doom.doom2.commercial: "DOOM 2: Hell on Earth"
I think that would bring back some sanity.
As it is now it will be an endless cause of problems for many users who fail to comprehend all the names and relationships. This would also make the definitions in iwadinfo.txt easier to read because there'd only be one string defining autoloading, not a complex relation ship of game, config, group and autoname.
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49234
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Sanitize autoloading
I have to concur. Just scanning through the INI to see what needs to be used where makes my head hurt. It was certainly well intentioned but badly executed.
I have been thinking already about what could be done, but this is certainly the best approach so far. With only one string to define all relevant autoload sections it'd greatly reduce the amount of redundancy and make collecting all autoload sections just scanning through the label string, add each sublabel one at a time and process the corresponding section, it should also be a lot easier to document.
Too bad that the INI format is not hierarchial to begin with, this section overload in the INI is surely not easy to read, especially if there's lots of custom keysections.
I have been thinking already about what could be done, but this is certainly the best approach so far. With only one string to define all relevant autoload sections it'd greatly reduce the amount of redundancy and make collecting all autoload sections just scanning through the label string, add each sublabel one at a time and process the corresponding section, it should also be a lot easier to document.
Too bad that the INI format is not hierarchial to begin with, this section overload in the INI is surely not easy to read, especially if there's lots of custom keysections.
Re: Sanitize autoloading
Couldn't this be improved with using hierarchical autoload folders?
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49234
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Sanitize autoloading
Sure. But let's make this manageable first before thinking about more new features. I already had some issues with the autoload stuff before this suggestion came - and as it so happens it presents the best solution so far to get rid of the naming mess that has developed.
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49234
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Sanitize autoloading
Done. I kept most of the suggested names, but changed 'square.full' to 'square.square' to keep this in line with other similar cases.
The new naming system will also be used for resource filtering.
One small piece of advice: If you migrate an old config file it will have to be loaded twice to create all supported autoload sections. This was done to avoid putting too much work into the migration code. Otherwise this would have been a lot more complicated because the section renaming has to be done after section creation resulting in duplicate names and a lot more code for something each user has to run only once.
As it is now the first time an old config is used it will just rename the existing autoload sections without adding the missing ones.
The new naming system will also be used for resource filtering.
One small piece of advice: If you migrate an old config file it will have to be loaded twice to create all supported autoload sections. This was done to avoid putting too much work into the migration code. Otherwise this would have been a lot more complicated because the section renaming has to be done after section creation resulting in duplicate names and a lot more code for something each user has to run only once.
As it is now the first time an old config is used it will just rename the existing autoload sections without adding the missing ones.
-
-
- Posts: 3209
- Joined: Wed Nov 24, 2004 12:59 pm
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
- Contact:
Re: Sanitize autoloading
Suggestion for Hacx: Please don't use "2.0" and "1.2". Just Hacx.2/Hacx.Revised/Hacx.Redux/Hacx.Complete and Hacx.1/Hacx.Classic/Hacx.Original. There is a mostly complete Hacx 1.3 waiting for us to have time to finish testing so specifying the complete version number is silly.
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49234
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Sanitize autoloading
Ok, no problem.
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49234
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Sanitize autoloading
How about 1.x and 2.x, I still think that the number should be there because it's the most prominent difference.
-
-
- Posts: 3209
- Joined: Wed Nov 24, 2004 12:59 pm
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
- Contact:
Re: Sanitize autoloading
Yeah, that would be good enough.
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49234
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Sanitize autoloading
OK, but since '.x' can't be done due to the dot in there I made it Hacx.1 and Hacx.2, just like Chex.1 and Chex.3
Re: Sanitize autoloading
Great solution. Thx.
But note: When you're going to use "doom2" as a subgame of "doom" (like "doom.doom2") you should use this system in other games too. That means to rename e.g. "chex.3" to "chex.chex3". Same in hacx.
//edit:
Or rename the subgames for doom and freedoom to the digit-system like in chex or hacx. But i think you shouldn't mix it.
But note: When you're going to use "doom2" as a subgame of "doom" (like "doom.doom2") you should use this system in other games too. That means to rename e.g. "chex.3" to "chex.chex3". Same in hacx.
//edit:
Or rename the subgames for doom and freedoom to the digit-system like in chex or hacx. But i think you shouldn't mix it.
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49234
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Sanitize autoloading
You are probably correct. Fortunately it's not too late to improve what's there. 

Re: Sanitize autoloading
So i would prefer a name-system like chex.chex3
//Oh, it's already done. Fine.
//Oh, it's already done. Fine.
Re: Sanitize autoloading
What about Strife? Maybe this?
Anyway: Is it usefull to allow autoloads for the teaser-versions of Strife?
Code: Select all
diff --git a/wadsrc/static/iwadinfo.txt b/wadsrc/static/iwadinfo.txt
index a274a1f..e39005f 100644
--- a/wadsrc/static/iwadinfo.txt
+++ b/wadsrc/static/iwadinfo.txt
@@ -90,7 +90,7 @@ IWad
IWad
{
Name = "Strife: Quest for the Sigil"
- Autoname = "strife"
+ Autoname = "strife.strife"
Game = "Strife"
Config = "Strife"
Mapinfo = "mapinfo/strife.txt"
@@ -104,7 +104,7 @@ IWad
Name = "Strife: Teaser (New Version)"
Game = "Strife"
Config = "Strife"
- Autoname = "strifeteaser2"
+ Autoname = "strife.teaser2"
Mapinfo = "mapinfo/strife.txt"
Compatibility = "Shareware", "Teaser2"
MustContain = "MAP33", "ENDSTRF", "INVCURS"
@@ -116,7 +116,7 @@ IWad
Name = "Strife: Teaser (Old Version)"
Game = "Strife"
Config = "Strife"
- Autoname = "strifeteaser1"
+ Autoname = "strife.teaser1"
Mapinfo = "mapinfo/strife.txt"
Compatibility = "Shareware"
MustContain = "MAP33", "ENDSTRF"
Re: Sanitize autoloading
And maybe some more future-stable changes?
Code: Select all
diff --git a/wadsrc/static/iwadinfo.txt b/wadsrc/static/iwadinfo.txt
index a274a1f..60c395a 100644
--- a/wadsrc/static/iwadinfo.txt
+++ b/wadsrc/static/iwadinfo.txt
@@ -3,7 +3,7 @@
IWad
{
Name = "The Adventures of Square"
- Autoname = "square.square"
+ Autoname = "square.episode1"
Game = "Doom"
Config = "Square"
MustContain = "SQU-IWAD", "E1A1"
@@ -13,7 +13,7 @@ IWad
IWad
{
Name = "The Adventures of Square (Square-ware)"
- Autoname = "square.squareware"
+ Autoname = "square.episode1.squareware"
Game = "Doom"
Config = "Square"
MustContain = "SQU-SWE1", "E1A1"
@@ -56,7 +56,7 @@ IWad
IWad
{
Name = "Action Doom 2: Urban Brawl"
- Autoname = "urbanbrawl"
+ Autoname = "actiondoom.urbanbrawl"
Game = "Doom"
Config = "UrbanBrawl"
Mapinfo = "mapinfo/urbanbrawl.txt"