diff --git a/src/main/java/ru/betterend/integration/byg/BYGFeatures.java b/src/main/java/ru/betterend/integration/byg/BYGFeatures.java index 22480ef8..39d0242b 100644 --- a/src/main/java/ru/betterend/integration/byg/BYGFeatures.java +++ b/src/main/java/ru/betterend/integration/byg/BYGFeatures.java @@ -10,12 +10,12 @@ import ru.betterend.world.features.WallPlantOnLogFeature; public class BYGFeatures { public static final EndFeature OLD_BULBIS_TREE = new EndFeature("old_bulbis_tree", new OldBulbisTreeFeature(), 1); - public static final EndFeature IVIS_SPROUT = new EndFeature("ivis_sprout", new SinglePlantFeature(Integrations.BYG.getBlock("ivis_sprout"), 6), 6); + public static final EndFeature IVIS_SPROUT = new EndFeature("ivis_sprout", new SinglePlantFeature(Integrations.BYG.getBlock("ivis_sprout"), 6, 2), 6); public static final EndFeature IVIS_VINE = new EndFeature("ivis_vine", new VineFeature(BYGBlocks.IVIS_VINE, 24), 5); public static final EndFeature IVIS_MOSS = new EndFeature("ivis_moss", new WallPlantFeature(BYGBlocks.IVIS_MOSS, 6), 1); public static final EndFeature IVIS_MOSS_WOOD = new EndFeature("ivis_moss_wood", new WallPlantOnLogFeature(BYGBlocks.IVIS_MOSS, 6), 15); - public static final EndFeature BULBIS_ODDITY = new EndFeature("bulbis_oddity", new SinglePlantFeature(Integrations.BYG.getBlock("bulbis_oddity"), 4), 5); - public static final EndFeature PURPLE_BULBIS_ODDITY = new EndFeature("purple_bulbis_oddity", new SinglePlantFeature(Integrations.BYG.getBlock("purple_bulbis_oddity"), 4), 5); + public static final EndFeature BULBIS_ODDITY = new EndFeature("bulbis_oddity", new SinglePlantFeature(Integrations.BYG.getBlock("bulbis_oddity"), 4, 4), 5); + public static final EndFeature PURPLE_BULBIS_ODDITY = new EndFeature("purple_bulbis_oddity", new SinglePlantFeature(Integrations.BYG.getBlock("purple_bulbis_oddity"), 4, 4), 5); public static final ConfiguredFeature BULBIS_TREES = Integrations.BYG.getConfiguredFeature("rs_sparse_bulbis_tree"); public static final ConfiguredFeature PURPLE_BULBIS_TREES = Integrations.BYG.getConfiguredFeature("rs_sparse_purple_bulbis_tree"); diff --git a/src/main/java/ru/betterend/world/features/SinglePlantFeature.java b/src/main/java/ru/betterend/world/features/SinglePlantFeature.java index 2d234913..89033266 100644 --- a/src/main/java/ru/betterend/world/features/SinglePlantFeature.java +++ b/src/main/java/ru/betterend/world/features/SinglePlantFeature.java @@ -13,15 +13,29 @@ import ru.betterend.util.BlocksHelper; public class SinglePlantFeature extends ScatterFeature { private final Block plant; private final boolean rawHeightmap; + private final int chance; public SinglePlantFeature(Block plant, int radius) { - this(plant, radius, true); + this(plant, radius, true, 1); + } + + public SinglePlantFeature(Block plant, int radius, int chance) { + this(plant, radius, true, chance); } public SinglePlantFeature(Block plant, int radius, boolean rawHeightmap) { + this(plant, radius, rawHeightmap, 1); + } + + public SinglePlantFeature(Block plant, int radius, boolean rawHeightmap, int chance) { super(radius); this.plant = plant; this.rawHeightmap = rawHeightmap; + this.chance = chance; + } + + protected int getChance() { + return chance; } @Override