public class LocationPredicate extends Object
Modifier and Type | Class and Description |
---|---|
static class |
LocationPredicate.Builder |
Modifier and Type | Field and Description |
---|---|
static LocationPredicate |
ANY |
private RegistryKey<Biome> |
biome |
private BlockPredicate |
block |
private RegistryKey<World> |
dimension |
private StructureFeature<?> |
feature |
private static Logger |
field_24732 |
private FluidPredicate |
fluid |
private LightPredicate |
light |
private Boolean |
smokey |
private NumberRange.FloatRange |
x |
private NumberRange.FloatRange |
y |
private NumberRange.FloatRange |
z |
Constructor and Description |
---|
LocationPredicate(NumberRange.FloatRange x,
NumberRange.FloatRange y,
NumberRange.FloatRange z,
RegistryKey<Biome> registryKey,
StructureFeature<?> feature,
RegistryKey<World> dimension,
Boolean smokey,
LightPredicate light,
BlockPredicate block,
FluidPredicate fluid) |
Modifier and Type | Method and Description |
---|---|
static LocationPredicate |
biome(RegistryKey<Biome> registryKey) |
static LocationPredicate |
dimension(RegistryKey<World> dimension) |
static LocationPredicate |
feature(StructureFeature<?> feature) |
static LocationPredicate |
fromJson(JsonElement json) |
boolean |
test(ServerWorld world,
double x,
double y,
double z) |
boolean |
test(ServerWorld world,
float x,
float y,
float z) |
JsonElement |
toJson() |
private static final Logger field_24732
public static final LocationPredicate ANY
private final NumberRange.FloatRange x
private final NumberRange.FloatRange y
private final NumberRange.FloatRange z
@Nullable private final RegistryKey<Biome> biome
@Nullable private final StructureFeature<?> feature
@Nullable private final RegistryKey<World> dimension
private final LightPredicate light
private final BlockPredicate block
private final FluidPredicate fluid
public LocationPredicate(NumberRange.FloatRange x, NumberRange.FloatRange y, NumberRange.FloatRange z, @Nullable RegistryKey<Biome> registryKey, @Nullable StructureFeature<?> feature, @Nullable RegistryKey<World> dimension, @Nullable Boolean smokey, LightPredicate light, BlockPredicate block, FluidPredicate fluid)
public static LocationPredicate biome(RegistryKey<Biome> registryKey)
public static LocationPredicate dimension(RegistryKey<World> dimension)
public static LocationPredicate feature(StructureFeature<?> feature)
public boolean test(ServerWorld world, double x, double y, double z)
public boolean test(ServerWorld world, float x, float y, float z)
public JsonElement toJson()
public static LocationPredicate fromJson(@Nullable JsonElement json)