Package cz.jeme.bestium.api.inject.biome
Interface BiomeFilter
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
A functional interface representing a predicate (boolean test) for
Biomes,
used to determine whether a biome satisfies specific criteria.
Filters can be composed using logical operations like and(cz.jeme.bestium.api.inject.biome.BiomeFilter...), or(cz.jeme.bestium.api.inject.biome.BiomeFilter...), or not(cz.jeme.bestium.api.inject.biome.BiomeFilter).
-
Method Summary
Modifier and TypeMethodDescriptionstatic BiomeFilterand(BiomeFilter... filters) Creates a filter that matches only biomes which match all of the provided filters.static BiomeFilterbaseTemperature(org.apache.commons.lang3.DoubleRange temperatureRange) Creates a filter that matches biomes with a base temperature within the given range.static BiomeFilterend()Creates a filter that matches biomes tagged withminecraft:is_end.static BiomeFilterCreates a filter that matches exactly one biome, identified by the given biome key.static BiomeFilterCreates a filter that matches any biome whose key is included in the provided set.static BiomeFilterCreates a filter that matches any biome whose key is included in the provided array of keys.static BiomeFilternether()Creates a filter that matches biomes tagged withminecraft:is_nether.static BiomeFilternot(BiomeFilter filter) Creates a filter that matches biomes that do not satisfy the given filter.static BiomeFilteror(BiomeFilter... filters) Creates a filter that matches biomes which match at least one of the provided filters.static BiomeFilterCreates a filter that matches biomes tagged withminecraft:is_overworld.static BiomeFilterCreates a filter that matches biomes assigned to the specified biome tag.booleantest(net.minecraft.world.level.biome.Biome biome) Tests whether the givenBiomematches the criteria defined by this filter.
-
Method Details
-
test
boolean test(net.minecraft.world.level.biome.Biome biome) Tests whether the givenBiomematches the criteria defined by this filter.- Parameters:
biome- the biome to test- Returns:
trueif the biome matches the filter,falseotherwise
-
and
Creates a filter that matches only biomes which match all of the provided filters.- Parameters:
filters- the filters to combine with a logical AND- Returns:
- a filter that matches biomes satisfying all given filters
-
or
Creates a filter that matches biomes which match at least one of the provided filters.- Parameters:
filters- the filters to combine with a logical OR- Returns:
- a filter that matches biomes satisfying any of the given filters
-
not
Creates a filter that matches biomes that do not satisfy the given filter.- Parameters:
filter- the filter to negate- Returns:
- a filter that matches the logical negation of the given filter
-
baseTemperature
Creates a filter that matches biomes with a base temperature within the given range.You may also use the predefined ranges in
BiomeTemperature.- Parameters:
temperatureRange- the inclusive temperature range to match- Returns:
- a filter matching biomes with a base temperature in the given range
- See Also:
-
tag
Creates a filter that matches biomes assigned to the specified biome tag.- Parameters:
tagKey- the key of the tag to match (e.g.,minecraft:is_savanna)- Returns:
- a filter that matches biomes tagged with the given key
- See Also:
-
key
Creates a filter that matches exactly one biome, identified by the given biome key.- Parameters:
biomeKey- the key of the biome to match- Returns:
- a filter that matches only the specified biome
- See Also:
-
keys
Creates a filter that matches any biome whose key is included in the provided set.- Parameters:
biomeKeys- the set of biome keys to match- Returns:
- a filter that matches any biome in the given set
- See Also:
-
keys
Creates a filter that matches any biome whose key is included in the provided array of keys.- Parameters:
first- the first biome keys to matchsecond- the second biome keys to matchrest- the rest of the biome keys to match- Returns:
- a filter that matches any biome in the given array of keys keys
- See Also:
-
overworld
Creates a filter that matches biomes tagged withminecraft:is_overworld.Note: This filter will not match most datapack biomes.
- Returns:
- a filter for vanilla overworld biomes
-
nether
Creates a filter that matches biomes tagged withminecraft:is_nether.Note: This filter will not match most datapack biomes.
- Returns:
- a filter for vanilla Nether biomes
-
end
Creates a filter that matches biomes tagged withminecraft:is_end.Note: This filter will not match most datapack biomes.
- Returns:
- a filter for vanilla End biomes
-