From fac5deef003f39d75fb1406a73fc4e917b22cbc9 Mon Sep 17 00:00:00 2001 From: DStrand1 Date: Thu, 30 Dec 2021 05:45:39 -0600 Subject: [PATCH] set a better range for rubber tree size --- .../java/gregtech/common/worldgen/WorldGenRubberTree.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main/java/gregtech/common/worldgen/WorldGenRubberTree.java b/src/main/java/gregtech/common/worldgen/WorldGenRubberTree.java index 7c013c82305..859202182d5 100644 --- a/src/main/java/gregtech/common/worldgen/WorldGenRubberTree.java +++ b/src/main/java/gregtech/common/worldgen/WorldGenRubberTree.java @@ -45,11 +45,12 @@ public boolean grow(World world, BlockPos pos, Random random) { if (height < 2) return false; height -= random.nextInt(height / 2 + 1); + height = Math.max(5, height); BlockPos.MutableBlockPos tmpPos = new BlockPos.MutableBlockPos(); for (int cHeight = 0; cHeight < height; cHeight++) { BlockPos cPos = pos.up(cHeight); setBlockAndNotifyAdequately(world, cPos, woodBlock); - if (height < 4 || (height < 7 && cHeight > 1) || cHeight > 2) { + if ((height < 7 && cHeight > 1) || cHeight > 2) { for (int cx = pos.getX() - 2; cx <= pos.getX() + 2; cx++) { for (int cz = pos.getZ() - 2; cz <= pos.getZ() + 2; cz++) { int chance = Math.max(1, cHeight + 4 - height); @@ -85,7 +86,7 @@ public int getGrowHeight(World world, BlockPos pos) { return 0; int height = 1; pos = pos.up(); - while (world.isAirBlock(pos) && height < 8) { + while (world.isAirBlock(pos) && height < 7) { pos = pos.up(); height++; }