From 44a65e8baea8d4f97f38989c84bc3df7a348a35d Mon Sep 17 00:00:00 2001 From: Frank Date: Thu, 30 Jun 2022 19:50:46 +0200 Subject: [PATCH] [Change] Wall Search can end inside wall --- .../features/CommonPlacedFeatureBuilder.java | 20 +++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/src/main/java/org/betterx/bclib/api/v3/levelgen/features/CommonPlacedFeatureBuilder.java b/src/main/java/org/betterx/bclib/api/v3/levelgen/features/CommonPlacedFeatureBuilder.java index ab009e10..9740100d 100644 --- a/src/main/java/org/betterx/bclib/api/v3/levelgen/features/CommonPlacedFeatureBuilder.java +++ b/src/main/java/org/betterx/bclib/api/v3/levelgen/features/CommonPlacedFeatureBuilder.java @@ -283,11 +283,15 @@ abstract class CommonPlacedFeatureBuilder, FC extends Feat * @see #findSolidSurface(Direction, int) for Details */ public T findSolidSurface(Direction dir, int distance) { - return modifier(new FindSolidInDirection(dir, distance)); + return modifier(new FindSolidInDirection(dir, distance, 0)); } public T findSolidSurface(List dir, int distance, boolean randomSelect) { - return modifier(new FindSolidInDirection(dir, distance, randomSelect)); + return modifier(new FindSolidInDirection(dir, distance, randomSelect, 0)); + } + + public T onWalls(int distance, int depth) { + return modifier(new FindSolidInDirection(PlaceFacingBlockConfig.HORIZONTAL, distance, false, depth)); } public T heightmap() { @@ -390,11 +394,19 @@ abstract class CommonPlacedFeatureBuilder, FC extends Feat return (T) this.count(countPerLayer).squarePlacement().underEveryLayerMin4().onlyInBiome(); } - public T betterNetherWall(int countPerLayer) { + public T betterNetherOnWall(int countPerLayer) { return (T) this.count(countPerLayer) .squarePlacement() .randomHeight4FromFloorCeil() - .modifier(new FindSolidInDirection(PlaceFacingBlockConfig.HORIZONTAL, 12, false)) + .onWalls(16, 0) + .onlyInBiome(); + } + + public T betterNetherInWall(int countPerLayer) { + return (T) this.count(countPerLayer) + .squarePlacement() + .randomHeight4FromFloorCeil() + .onWalls(16, 1) .onlyInBiome(); }