public static class BlockUsedCriterion.Conditions extends AbstractCriterionConditions
Modifier and Type | Field and Description |
---|---|
private BlockPredicate |
block |
private ItemPredicate |
item |
private StatePredicate |
state |
Constructor and Description |
---|
Conditions(Identifier id,
BlockPredicate block,
StatePredicate state,
ItemPredicate item) |
Modifier and Type | Method and Description |
---|---|
static BlockUsedCriterion.Conditions |
create(BlockPredicate.Builder blockPredicateBuilder,
ItemPredicate.Builder itemPredicateBuilder) |
boolean |
test(BlockState state,
ServerWorld world,
BlockPos pos,
ItemStack stack) |
JsonElement |
toJson() |
getId, toString
private final BlockPredicate block
private final StatePredicate state
private final ItemPredicate item
public Conditions(Identifier id, BlockPredicate block, StatePredicate state, ItemPredicate item)
public static BlockUsedCriterion.Conditions create(BlockPredicate.Builder blockPredicateBuilder, ItemPredicate.Builder itemPredicateBuilder)
public boolean test(BlockState state, ServerWorld world, BlockPos pos, ItemStack stack)
public JsonElement toJson()