Config for Oregen. Closes #2062
This commit is contained in:
parent
8f64355885
commit
7138a8d45b
2 changed files with 97 additions and 17 deletions
|
@ -592,4 +592,52 @@ public class TechRebornConfig {
|
|||
|
||||
@Config(config = "world", category = "loot", key = "enableEndLoot", comment = "When true TechReborn will add ingots, machine frames and circuits to The End loot chests.")
|
||||
public static boolean enableEndLoot = true;
|
||||
|
||||
@Config(config = "world", category = "ore", key = "enableBauxiteOre", comment = "Generate Bauxite Ore in The Overworld.")
|
||||
public static boolean enableBauxiteOre = true;
|
||||
|
||||
@Config(config = "world", category = "ore", key = "enableCopperOre", comment = "Generate Copper Ore in The Overworld.")
|
||||
public static boolean enableCopperOre = true;
|
||||
|
||||
@Config(config = "world", category = "ore", key = "enableGalenaOre", comment = "Generate Galena Ore in The Overworld.")
|
||||
public static boolean enableGalenaOre = true;
|
||||
|
||||
@Config(config = "world", category = "ore", key = "enableIridiumOre", comment = "Generate Iridium Ore in The Overworld.")
|
||||
public static boolean enableIridiumOre = true;
|
||||
|
||||
@Config(config = "world", category = "ore", key = "enableLeadOre", comment = "Generate Lead Ore in The Overworld.")
|
||||
public static boolean enableLeadOre = true;
|
||||
|
||||
@Config(config = "world", category = "ore", key = "enableRubyOre", comment = "Generate Ruby Ore in The Overworld.")
|
||||
public static boolean enableRubyOre = true;
|
||||
|
||||
@Config(config = "world", category = "ore", key = "enableSapphireOre", comment = "Generate Sapphire Ore in The Overworld.")
|
||||
public static boolean enableSapphireOre = true;
|
||||
|
||||
@Config(config = "world", category = "ore", key = "enableSilverOre", comment = "Generate Silver Ore in The Overworld.")
|
||||
public static boolean enableSilverOre = true;
|
||||
|
||||
@Config(config = "world", category = "ore", key = "enableTinOre", comment = "Generate Tin Ore in The Overworld.")
|
||||
public static boolean enableTinOre = true;
|
||||
|
||||
@Config(config = "world", category = "ore", key = "enableCinnabarOre", comment = "Generate Cinnabar Ore in The Nether.")
|
||||
public static boolean enableCinnabarOre = true;
|
||||
|
||||
@Config(config = "world", category = "ore", key = "enablePyriteOre", comment = "Generate Pyrite Ore in The Nether.")
|
||||
public static boolean enablePyriteOre = true;
|
||||
|
||||
@Config(config = "world", category = "ore", key = "enableSphaleriteOre", comment = "Generate Sphalerite Ore in The Nether.")
|
||||
public static boolean enableSphaleriteOre = true;
|
||||
|
||||
@Config(config = "world", category = "ore", key = "enablePeridotOre", comment = "Generate Peridot Ore in The End.")
|
||||
public static boolean enablePeridotOre = true;
|
||||
|
||||
@Config(config = "world", category = "ore", key = "enableSheldoniteOre", comment = "Generate Sheldonite Ore in The End.")
|
||||
public static boolean enableSheldoniteOre = true;
|
||||
|
||||
@Config(config = "world", category = "ore", key = "enableSodaliteOre", comment = "Generate Sodalite Ore in The End.")
|
||||
public static boolean enableSodaliteOre = true;
|
||||
|
||||
@Config(config = "world", category = "ore", key = "enableTungstenOre", comment = "Generate Tungsten Ore in The End.")
|
||||
public static boolean enableTungstenOre = true;
|
||||
}
|
||||
|
|
|
@ -45,6 +45,7 @@ import net.minecraft.world.gen.stateprovider.WeightedStateProvider;
|
|||
import reborncore.common.world.CustomOreFeature;
|
||||
import reborncore.common.world.CustomOreFeatureConfig;
|
||||
import techreborn.blocks.misc.BlockRubberLog;
|
||||
import techreborn.config.TechRebornConfig;
|
||||
import techreborn.init.TRContent;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
@ -108,25 +109,56 @@ public class WorldGenerator {
|
|||
checkedBiomes.add(biome);
|
||||
|
||||
if (biome.getCategory() == Category.NETHER) {
|
||||
addOre(biome, OreFeatureConfig.Target.NETHERRACK, TRContent.Ores.CINNABAR);
|
||||
addOre(biome, OreFeatureConfig.Target.NETHERRACK, TRContent.Ores.PYRITE);
|
||||
addOre(biome, OreFeatureConfig.Target.NETHERRACK, TRContent.Ores.SPHALERITE);
|
||||
|
||||
if (TechRebornConfig.enableCinnabarOre){
|
||||
addOre(biome, OreFeatureConfig.Target.NETHERRACK, TRContent.Ores.CINNABAR);
|
||||
}
|
||||
if (TechRebornConfig.enablePyriteOre){
|
||||
addOre(biome, OreFeatureConfig.Target.NETHERRACK, TRContent.Ores.PYRITE);
|
||||
}
|
||||
if (TechRebornConfig.enableSphaleriteOre){
|
||||
addOre(biome, OreFeatureConfig.Target.NETHERRACK, TRContent.Ores.SPHALERITE);
|
||||
}
|
||||
} else if (biome.getCategory() == Category.THEEND) {
|
||||
addEndOre(biome, TRContent.Ores.PERIDOT);
|
||||
addEndOre(biome, TRContent.Ores.SHELDONITE);
|
||||
addEndOre(biome, TRContent.Ores.SODALITE);
|
||||
addEndOre(biome, TRContent.Ores.TUNGSTEN);
|
||||
if (TechRebornConfig.enableSphaleriteOre){
|
||||
addEndOre(biome, TRContent.Ores.PERIDOT);
|
||||
}
|
||||
if (TechRebornConfig.enableSheldoniteOre){
|
||||
addEndOre(biome, TRContent.Ores.SHELDONITE);
|
||||
}
|
||||
if (TechRebornConfig.enableSodaliteOre){
|
||||
addEndOre(biome, TRContent.Ores.SODALITE);
|
||||
}
|
||||
if (TechRebornConfig.enableTungstenOre){
|
||||
addEndOre(biome, TRContent.Ores.TUNGSTEN);
|
||||
}
|
||||
} else {
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.BAUXITE);
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.COPPER);
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.GALENA);
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.IRIDIUM);
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.LEAD);
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.RUBY);
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.SAPPHIRE);
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.SILVER);
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.TIN);
|
||||
if (TechRebornConfig.enableBauxiteOre){
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.BAUXITE);
|
||||
}
|
||||
if (TechRebornConfig.enableBauxiteOre){
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.COPPER);
|
||||
}
|
||||
if (TechRebornConfig.enableGalenaOre){
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.GALENA);
|
||||
}
|
||||
if (TechRebornConfig.enableIridiumOre){
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.IRIDIUM);
|
||||
}
|
||||
if (TechRebornConfig.enableLeadOre){
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.LEAD);
|
||||
}
|
||||
if (TechRebornConfig.enableRubyOre){
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.RUBY);
|
||||
}
|
||||
if (TechRebornConfig.enableSapphireOre) {
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.SAPPHIRE);
|
||||
}
|
||||
if (TechRebornConfig.enableSilverOre) {
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.SILVER);
|
||||
}
|
||||
if (TechRebornConfig.enableTinOre) {
|
||||
addOre(biome, OreFeatureConfig.Target.NATURAL_STONE, TRContent.Ores.TIN);
|
||||
}
|
||||
|
||||
if (biome.getCategory() == Category.FOREST || biome.getCategory() == Category.TAIGA || biome.getCategory() == Category.SWAMP) {
|
||||
biome.addFeature(GenerationStep.Feature.VEGETAL_DECORATION,
|
||||
|
|
Loading…
Reference in a new issue