diff --git a/src/main/java/techreborn/Core.java b/src/main/java/techreborn/Core.java index 72874b8c2..c6b2cf9e8 100644 --- a/src/main/java/techreborn/Core.java +++ b/src/main/java/techreborn/Core.java @@ -110,7 +110,9 @@ public class Core { public void init(FMLInitializationEvent event) throws IllegalAccessException, InstantiationException { //World gen VeinWorldGenerator.registerTRVeins(); - GameRegistry.registerWorldGenerator(VeinWorldGenerator.INSTANCE, 0); + if(ConfigTechReborn.veinOres){ + GameRegistry.registerWorldGenerator(VeinWorldGenerator.INSTANCE, 0); + } // Registers Chest Loot ModLoot.init(); // Multiparts @@ -136,7 +138,9 @@ public class Core { proxy.init(event); // WorldGen worldGen.load(); - //GameRegistry.registerWorldGenerator(worldGen, 0); + if(!ConfigTechReborn.veinOres){ + GameRegistry.registerWorldGenerator(worldGen, 0); + } // DungeonLoot.init(); // Register Gui Handler diff --git a/src/main/java/techreborn/config/ConfigTechReborn.java b/src/main/java/techreborn/config/ConfigTechReborn.java index eceddd19d..784edd2d8 100644 --- a/src/main/java/techreborn/config/ConfigTechReborn.java +++ b/src/main/java/techreborn/config/ConfigTechReborn.java @@ -146,6 +146,8 @@ public class ConfigTechReborn public static boolean enableGemArmorAndTools; + public static boolean veinOres; + public static Configuration config; private static ConfigTechReborn instance = null; @@ -199,6 +201,10 @@ public class ConfigTechReborn .get(CATEGORY_WORLD, "Steel Ingots Loot", true, "Allow Steel Ingots to generate in loot chests") .getBoolean(true); + veinOres = config + .get(CATEGORY_WORLD, "Custom Ore veins", false, "Use the new style GT vein ore generation - game restart required") + .getBoolean(false); + FortuneSecondaryOreMultiplierPerLevel = config.get(CATEGORY_WORLD, "FortuneSecondaryOreMultiplierPerLevel", 0.5, "FortuneSecondaryOreMultiplierPerLevel").getDouble(); diff --git a/src/main/java/techreborn/world/veins/VeinGenerator.java b/src/main/java/techreborn/world/veins/VeinGenerator.java index 4c871bc75..856383b28 100644 --- a/src/main/java/techreborn/world/veins/VeinGenerator.java +++ b/src/main/java/techreborn/world/veins/VeinGenerator.java @@ -81,17 +81,6 @@ public class VeinGenerator { return true; } - for(int i = 0; i < 16; i++) { - for(int j = 0; j < 16; j++) { - for(int k = 0; k < world.provider.getAverageGroundLevel(); ++k) { - BlockPos pos = new BlockPos(chunkX * 16 + i, k, chunkZ * 16 + j); - if(world.getBlockState(pos).getBlock() == Blocks.STONE) { - world.setBlockToAir(pos); - } - } - } - } - return false; }