Class BiomeModifications
java.lang.Object
net.fabricmc.fabric.api.biome.v1.BiomeModifications
Provides an API to modify Biomes after they have been loaded and before they are used in the Level.
Any modifications made to biomes will not be available for use in the demo level.
-
Method Summary
Modifier and TypeMethodDescriptionstatic voidaddCarver(Predicate<BiomeSelectionContext> biomeSelector, net.minecraft.resources.ResourceKey<net.minecraft.world.level.levelgen.carver.ConfiguredWorldCarver<?>> configuredCarverKey) Convenience method to add a carver to one or more biomes.static voidaddFeature(Predicate<BiomeSelectionContext> biomeSelector, net.minecraft.world.level.levelgen.GenerationStep.Decoration step, net.minecraft.resources.ResourceKey<net.minecraft.world.level.levelgen.placement.PlacedFeature> placedFeatureKey) Convenience method to add a feature to one or more biomes.static voidaddSpawn(Predicate<BiomeSelectionContext> biomeSelector, net.minecraft.world.entity.MobCategory category, net.minecraft.world.entity.EntityType<?> entityType, int weight, int minGroupSize, int maxGroupSize) Convenience method to add an entity spawn to one or more biomes.static BiomeModificationcreate(net.minecraft.resources.Identifier id) Creates a new biome modification which will be applied whenever biomes are loaded from data packs.
-
Method Details
-
addFeature
public static void addFeature(Predicate<BiomeSelectionContext> biomeSelector, net.minecraft.world.level.levelgen.GenerationStep.Decoration step, net.minecraft.resources.ResourceKey<net.minecraft.world.level.levelgen.placement.PlacedFeature> placedFeatureKey) Convenience method to add a feature to one or more biomes.- See Also:
-
addCarver
public static void addCarver(Predicate<BiomeSelectionContext> biomeSelector, net.minecraft.resources.ResourceKey<net.minecraft.world.level.levelgen.carver.ConfiguredWorldCarver<?>> configuredCarverKey) Convenience method to add a carver to one or more biomes.- See Also:
-
addSpawn
public static void addSpawn(Predicate<BiomeSelectionContext> biomeSelector, net.minecraft.world.entity.MobCategory category, net.minecraft.world.entity.EntityType<?> entityType, int weight, int minGroupSize, int maxGroupSize) Convenience method to add an entity spawn to one or more biomes.- See Also:
-
create
Creates a new biome modification which will be applied whenever biomes are loaded from data packs.- Parameters:
id- An identifier for the new set of biome modifications that is returned. Is used for guaranteeing consistent ordering between the biome modifications added by different mods (assuming they otherwise have the same phase).
-