Fenced config opt-out processing with exception handling.
This commit is contained in:
parent
1e2c8fe7eb
commit
a561e61e35
5 changed files with 12 additions and 6 deletions
|
@ -7,4 +7,4 @@ meta_download=https://www.curseforge.com/minecraft/mc-mods/engineers-decor/
|
|||
version_minecraft=1.19.2
|
||||
version_forge_minecraft=1.19.2-43.1.16
|
||||
version_jei=11.3.0.262
|
||||
version_engineersdecor=1.3.28
|
||||
version_engineersdecor=1.3.29
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
{
|
||||
"homepage": "https://www.curseforge.com/minecraft/mc-mods/engineers-decor/",
|
||||
"1.19.2": {
|
||||
"1.3.29": "[F] Fenced config opt-out processing with exception handling in case config apply is called before registry events have finished.",
|
||||
"1.3.28": "[F] Steel Mesh Fence help typo fixed (issue #227, ty shrad).\n[A] Added \"tree_cutter_universal_logs\" server config to enable chopping of modded resource wood blocks (e.g. rubber, issue #228).",
|
||||
"1.3.27": "[F] Refactored deprecated forge capability references.\n[F] Fixed Factory Hopper on-break item retention bug (issue #226, ty sunekaer/ftb).",
|
||||
"1.3.26": "[U] Ported to 1.19.2.\n[F] Fixed Mineral Melting Furnace fluid extraction (issue #223, ty adkinss).",
|
||||
|
@ -63,7 +64,7 @@
|
|||
"1.1.2-b1": "[U] Ported to MC1.16.2."
|
||||
},
|
||||
"promos": {
|
||||
"1.19.2-recommended": "1.3.28",
|
||||
"1.19.2-latest": "1.3.28"
|
||||
"1.19.2-recommended": "1.3.29",
|
||||
"1.19.2-latest": "1.3.29"
|
||||
}
|
||||
}
|
|
@ -11,6 +11,9 @@ Mod sources for Minecraft version 1.18.x.
|
|||
|
||||
## Version history
|
||||
|
||||
- v1.3.29 [F] Fenced config opt-out processing with exception handling in case config
|
||||
apply is called before registry events have finished.
|
||||
|
||||
- v1.3.28 [F] Steel Mesh Fence help typo fixed (issue #227, ty shrad).
|
||||
[A] Added "tree_cutter_universal_logs" server config to enable chopping of modded
|
||||
resource wood blocks (e.g. rubber, issue #228).
|
||||
|
|
|
@ -382,7 +382,7 @@ public class ModConfig
|
|||
}
|
||||
if(!excludes.isEmpty()) log("Config pattern excludes: '" + String.join(",", excludes) + "'");
|
||||
if(!includes.isEmpty()) log("Config pattern includes: '" + String.join(",", includes) + "'");
|
||||
{
|
||||
try {
|
||||
HashSet<String> optouts = new HashSet<>();
|
||||
ModContent.getRegisteredBlocks().stream().filter((Block block) -> {
|
||||
if(block==null) return true;
|
||||
|
@ -419,8 +419,10 @@ public class ModConfig
|
|||
e -> optouts.add(Auxiliaries.getResourceLocation(e).getPath())
|
||||
);
|
||||
optouts_ = optouts;
|
||||
OptionalRecipeCondition.on_config(withExperimental(), withoutRecipes(), ModConfig::isOptedOut, ModConfig::isOptedOut);
|
||||
} catch(Throwable ex) {
|
||||
Auxiliaries.logger().error("Exception evaluating the optout config: '"+ex.getMessage()+"'"); // Compat issue: config-apply may be called before the registries are all loaded.
|
||||
}
|
||||
OptionalRecipeCondition.on_config(withExperimental(), withoutRecipes(), ModConfig::isOptedOut, ModConfig::isOptedOut);
|
||||
}
|
||||
|
||||
public static void apply()
|
||||
|
|
|
@ -79,7 +79,7 @@ public class Auxiliaries
|
|||
{ return logger; }
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
// Sideness, system/environment, tagging interfaces
|
||||
// Sidedness, system/environment, tagging interfaces
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public interface IExperimentalFeature {}
|
||||
|
|
Loading…
Reference in a new issue