Skip to content

Commit

Permalink
Underwater root cluster compatibility (#348)
Browse files Browse the repository at this point in the history
  • Loading branch information
RivervdMeulen authored Aug 10, 2024
1 parent 32787fc commit 95b0231
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,16 @@

import net.minecraft.core.Holder;
import net.minecraft.core.HolderGetter;
import net.minecraft.core.Vec3i;
import net.minecraft.core.registries.Registries;
import net.minecraft.data.worldgen.BootstapContext;
import net.minecraft.resources.ResourceKey;
import net.minecraft.resources.ResourceLocation;
import net.minecraft.world.level.levelgen.VerticalAnchor;
import net.minecraft.world.level.levelgen.blockpredicates.BlockPredicate;
import net.minecraft.world.level.levelgen.feature.ConfiguredFeature;
import net.minecraft.world.level.levelgen.placement.*;
import net.minecraft.world.level.material.Fluids;
import whocraft.tardis_refined.TardisRefined;
import whocraft.tardis_refined.registry.TRFeatureKeys;

Expand All @@ -31,7 +34,8 @@ public static void bootstrap(BootstapContext<PlacedFeature> context) {
List.of(
RarityFilter.onAverageOnceEvery(25),
InSquarePlacement.spread(),
HeightRangePlacement.uniform(VerticalAnchor.absolute(-50), VerticalAnchor.absolute(20))))
HeightRangePlacement.uniform(VerticalAnchor.absolute(-50), VerticalAnchor.absolute(20)),
BlockPredicateFilter.forPredicate(BlockPredicate.not(BlockPredicate.matchesFluids(new Vec3i(0, 5, 0), Fluids.WATER)))))
);


Expand Down

0 comments on commit 95b0231

Please sign in to comment.