16 lines
641 B
Java
16 lines
641 B
Java
|
package net.minecraft.world.level.levelgen.structure.templatesystem;
|
||
|
|
||
|
import com.mojang.serialization.Codec;
|
||
|
import net.minecraft.core.BlockPos;
|
||
|
import net.minecraft.core.registries.BuiltInRegistries;
|
||
|
import net.minecraft.util.RandomSource;
|
||
|
|
||
|
public abstract class PosRuleTest {
|
||
|
public static final Codec<PosRuleTest> CODEC = BuiltInRegistries.POS_RULE_TEST
|
||
|
.byNameCodec()
|
||
|
.dispatch("predicate_type", PosRuleTest::getType, PosRuleTestType::codec);
|
||
|
|
||
|
public abstract boolean test(BlockPos p_230305_, BlockPos p_230306_, BlockPos p_230307_, RandomSource p_230308_);
|
||
|
|
||
|
protected abstract PosRuleTestType<?> getType();
|
||
|
}
|