Package net.minecraft.world.level
Interface BlockGetter
- All Superinterfaces:
IBlockGetterExtension,LevelHeightAccessor
- All Known Subinterfaces:
BlockAndTintGetter,CollisionGetter,CommonLevelAccessor,LevelAccessor,LevelReader,LevelTimeAccess,LightChunk,ServerLevelAccessor,SignalGetter,WorldGenLevel
- All Known Implementing Classes:
ChunkAccess,ClientLevel,EmptyBlockGetter,EmptyLevelChunk,ImposterProtoChunk,Level,LevelChunk,PathNavigationRegion,ProtoChunk,RenderChunkRegion,ServerLevel,WorldGenRegion
-
Method Summary
Modifier and TypeMethodDescriptiondefault BlockHitResultclip(ClipContext pContext) Checks if there's block betweenfromandtoof context.default BlockHitResultclipWithInteractionOverride(Vec3 pStartVec, Vec3 pEndVec, BlockPos pPos, VoxelShape pShape, BlockState pState) getBlockEntity(BlockPos pPos) default <T extends BlockEntity>
Optional<T> getBlockEntity(BlockPos pPos, BlockEntityType<T> pBlockEntityType) default doublegetBlockFloorHeight(BlockPos pPos) default doublegetBlockFloorHeight(VoxelShape pShape, Supplier<VoxelShape> pBelowShapeSupplier) getBlockState(BlockPos p_45571_) default Stream<BlockState> getBlockStates(AABB pArea) getFluidState(BlockPos pPos) default intgetLightEmission(BlockPos pPos) default intdefault BlockHitResultisBlockInLine(ClipBlockStateContext pContext) static <T,C> T traverseBlocks(Vec3 pFrom, Vec3 pTo, C pContext, BiFunction<C, BlockPos, T> pTester, Function<C, T> pOnFail) Methods inherited from interface net.neoforged.neoforge.common.extensions.IBlockGetterExtension
getAuxLightManager, getAuxLightManager, getModelDataMethods inherited from interface net.minecraft.world.level.LevelHeightAccessor
getHeight, getMaxBuildHeight, getMaxSection, getMinBuildHeight, getMinSection, getSectionIndex, getSectionIndexFromSectionY, getSectionsCount, getSectionYFromSectionIndex, isOutsideBuildHeight, isOutsideBuildHeight
-
Method Details
-
getBlockEntity
-
getBlockEntity
default <T extends BlockEntity> Optional<T> getBlockEntity(BlockPos pPos, BlockEntityType<T> pBlockEntityType) -
getBlockState
-
getFluidState
-
getLightEmission
-
getMaxLightLevel
default int getMaxLightLevel() -
getBlockStates
-
isBlockInLine
-
clip
Checks if there's block betweenfromandtoof context. This uses the collision shape of provided block. -
clipWithInteractionOverride
@Nullable default BlockHitResult clipWithInteractionOverride(Vec3 pStartVec, Vec3 pEndVec, BlockPos pPos, VoxelShape pShape, BlockState pState) -
getBlockFloorHeight
-
getBlockFloorHeight
-
traverseBlocks
static <T,C> T traverseBlocks(Vec3 pFrom, Vec3 pTo, C pContext, BiFunction<C, BlockPos, T> pTester, Function<C, T> pOnFail)
-