Interface BlockApiLookup.BlockApiProvider<A, C extends @Nullable Object>
- Enclosing interface:
BlockApiLookup<A, C extends @Nullable Object>
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface
public static interface BlockApiLookup.BlockApiProvider<A, C extends @Nullable Object>
-
Method Summary
Modifier and TypeMethodDescription@Nullable Afind(net.minecraft.world.level.Level level, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state, @Nullable net.minecraft.world.level.block.entity.BlockEntity blockEntity, C context) Return an API of typeAif available in the level at the given pos with the given context, ornullotherwise.
-
Method Details
-
find
@Nullable A find(net.minecraft.world.level.Level level, net.minecraft.core.BlockPos pos, net.minecraft.world.level.block.state.BlockState state, @Nullable net.minecraft.world.level.block.entity.BlockEntity blockEntity, C context) Return an API of typeAif available in the level at the given pos with the given context, ornullotherwise.- Parameters:
level- The level.pos- The position in the level.state- The block state.blockEntity- The block entity, if it exists in the level.context- Additional context passed to the query.- Returns:
- An API of type
A, ornullif no API is available.
-