diff --git a/1.12/src/main/java/wile/engineersdecor/ModContent.java b/1.12/src/main/java/wile/engineersdecor/ModContent.java index 6138e72..9666f5d 100644 --- a/1.12/src/main/java/wile/engineersdecor/ModContent.java +++ b/1.12/src/main/java/wile/engineersdecor/ModContent.java @@ -599,7 +599,7 @@ public class ModContent }; private static final Object dev_content[] = { - SIGN_MINDSTEP, + SIGN_MINDSTEP, // @todo: somehow make this sign look good. PANZERGLASS_SLAB, // @todo: check if another class is needed due to is_side_visible TREATED_WOOD_FLOOR, // @todo: check if textures need improvement TEST_BLOCK,TEST_BLOCK_TEI, diff --git a/1.14/gradle.properties b/1.14/gradle.properties index 23280ca..c4daaf7 100644 --- a/1.14/gradle.properties +++ b/1.14/gradle.properties @@ -5,4 +5,4 @@ version_minecraft=1.14.4 version_forge_minecraft=1.14.4-28.1.90 version_fml_mappings=20190719-1.14.3 version_jei=1.14.4:6.0.0.10 -version_engineersdecor=1.0.16-b4 +version_engineersdecor=1.0.16-b5 diff --git a/1.14/meta/update.json b/1.14/meta/update.json index e0c63a2..7f53562 100644 --- a/1.14/meta/update.json +++ b/1.14/meta/update.json @@ -1,6 +1,7 @@ { "homepage": "https://www.curseforge.com/minecraft/mc-mods/engineers-decor/", "1.14.4": { + "1.0.16-b5": "[F] Fixed recipe condition bug (issue #65, thx Nachtflame for the report, and gigaherz & killjoy for the help).", "1.0.16-b4": "[U] Updated to Forge 1.14.4-28.1.90/20190719-1.14.3.\n[M] Increased slag brick recipe yield to 8.\n[M] Parent specs in model files adapted.", "1.0.16-b3": "[A] Config options (opt-outs and tweaks) added.\n[M] Increased clinker brick recipe yield to 8 for the builders needs.", "1.0.16-b2": "[A] Added Gas Concrete (including wall, stairs, slab, and slab slice).\n[F] Fixed Small Block Breaker active model.\n[F] Fixed item-on-ground display glitch (issue #61, thx Federsavo for the hint).\n[F] Added two missing recipes.", @@ -34,6 +35,6 @@ }, "promos": { "1.14.4-recommended": "", - "1.14.4-latest": "1.0.16-b4" + "1.14.4-latest": "1.0.16-b5" } } \ No newline at end of file diff --git a/1.14/readme.md b/1.14/readme.md index d023d85..85790eb 100644 --- a/1.14/readme.md +++ b/1.14/readme.md @@ -11,6 +11,9 @@ Mod sources for Minecraft version 1.14.4. ## Version history + - v1.0.16-b5 [F] Fixed recipe condition bug (issue #65, thx Nachtflame for the report, + and gigaherz & killjoy for the help). + - v1.0.16-b4 [U] Updated to Forge 1.14.4-28.1.90/20190719-1.14.3. [M] Increased slag brick recipe yield to 8. [M] Parent specs in model files adapted. diff --git a/1.14/src/main/java/wile/engineersdecor/detail/ModConfig.java b/1.14/src/main/java/wile/engineersdecor/detail/ModConfig.java index f5b7df6..1c94320 100644 --- a/1.14/src/main/java/wile/engineersdecor/detail/ModConfig.java +++ b/1.14/src/main/java/wile/engineersdecor/detail/ModConfig.java @@ -17,7 +17,6 @@ import net.minecraft.block.Block; import net.minecraft.item.Item; import net.minecraftforge.common.ForgeConfigSpec; import org.apache.commons.lang3.tuple.Pair; -import wile.engineersdecor.blocks.BlockDecorMilker.BTileEntity; import javax.annotation.Nullable; import java.util.ArrayList; @@ -461,7 +460,7 @@ public class ModConfig "Note this is a permanent standby power, not only when the device does something. " + "Use zero to disable energy dependency and energy handling of the machine. " + "The config value can be changed on-the-fly for tuning.") - .defineInRange("milking_machine_energy_consumption", BTileEntity.DEFAULT_ENERGY_CONSUMPTION, 0, 128); + .defineInRange("milking_machine_energy_consumption", BlockDecorMilker.BTileEntity.DEFAULT_ENERGY_CONSUMPTION, 0, 128); builder.pop(); } } @@ -564,6 +563,9 @@ public class ModConfig public static boolean withExperimental() { return with_experimental_features_; } + public static boolean withoutRecipes() + { return without_recipes_; } + //-------------------------------------------------------------------------------------------------------------------- // Cache //-------------------------------------------------------------------------------------------------------------------- @@ -573,6 +575,7 @@ public class ModConfig public static boolean without_crafting_table = false; public static boolean immersiveengineering_installed = false; private static boolean with_experimental_features_ = false; + private static boolean without_recipes_ = false; public static final CompoundNBT getServerConfig() // config that may be synchronized from server to client via net pkg. { return server_config_; } @@ -592,6 +595,7 @@ public class ModConfig without_crafting_table = isOptedOut(ModContent.TREATED_WOOD_CRAFTING_TABLE); immersiveengineering_installed = ModAuxiliaries.isModLoaded("immersiveengineering"); with_experimental_features_ = COMMON.with_experimental.get(); + without_recipes_ = COMMON.without_recipes.get(); if(with_experimental_features_) { ModEngineersDecor.logger().info("Config: EXPERIMENTAL FEATURES ENABLED."); } diff --git a/1.14/src/main/java/wile/engineersdecor/detail/OptionalRecipeCondition.java b/1.14/src/main/java/wile/engineersdecor/detail/OptionalRecipeCondition.java index c13f213..66ec968 100644 --- a/1.14/src/main/java/wile/engineersdecor/detail/OptionalRecipeCondition.java +++ b/1.14/src/main/java/wile/engineersdecor/detail/OptionalRecipeCondition.java @@ -57,11 +57,16 @@ public class OptionalRecipeCondition implements ICondition @Override public boolean test() { + if(ModConfig.withoutRecipes()) return false; if((experimental) && (!ModConfig.withExperimental())) return false; final IForgeRegistry block_registry = ForgeRegistries.BLOCKS; final IForgeRegistry item_registry = ForgeRegistries.ITEMS; if(result != null) { - if((!block_registry.containsKey(result)) && (!item_registry.containsKey(result))) return false; // required result not registered + boolean item_registered = item_registry.containsKey(result); + boolean block_registered = block_registry.containsKey(result); + if((!block_registered) && (!item_registered)) return false; // required result not registered + if(item_registered && ModConfig.isOptedOut(item_registry.getValue(result))) return false; + if(block_registered && ModConfig.isOptedOut(block_registry.getValue(result))) return false; } if(!all_required.isEmpty()) { for(ResourceLocation rl:all_required) { diff --git a/meta/update.json b/meta/update.json index b833db2..85c0d4d 100644 --- a/meta/update.json +++ b/meta/update.json @@ -4,7 +4,7 @@ "1.12.2-recommended": "1.0.15", "1.12.2-latest": "1.0.16-b3", "1.14.4-recommended": "", - "1.14.4-latest": "1.0.16-b4" + "1.14.4-latest": "1.0.16-b5" }, "1.12.2": { "1.0.16-b3": "[M] Increased slag brick recipe yield to 8.\n[A] Small Block Placer can plant Cocoa.\n[F] Fixed Small Block Placer seed detection issue (issue #64, thx Federsavo).\n[F] Fixed incorrectly enabled alternative recipes for fluid accumulator and check valve when IE is installed.\n[M] Slightly nerfed the Small Solar Panel default peak power output (does not affect existing configurations).", @@ -74,6 +74,7 @@ "1.0.0-b1": "[A] Initial structure.\n[A] Added clinker bricks and clinker brick stairs.\n[A] Added slag bricks and slag brick stairs.\n[A] Added metal rung ladder.\n[A] Added staggered metal steps ladder.\n[A] Added treated wood ladder.\n[A] Added treated wood pole.\n[A] Added treated wood table." }, "1.14.4": { + "1.0.16-b5": "[F] Fixed recipe condition bug (issue #65, thx Nachtflame for the report, and gigaherz & killjoy for the help).", "1.0.16-b4": "[U] Updated to Forge 1.14.4-28.1.90/20190719-1.14.3.\n[M] Increased slag brick recipe yield to 8.\n[M] Parent specs in model files adapted.", "1.0.16-b3": "[A] Config options (opt-outs and tweaks) added.\n[M] Increased clinker brick recipe yield to 8 for the builders needs.", "1.0.16-b2": "[A] Added Gas Concrete (including wall, stairs, slab, and slab slice).\n[F] Fixed Small Block Breaker active model.\n[F] Fixed item-on-ground display glitch (issue #61, thx Federsavo for the hint).\n[F] Added two missing recipes.",