Package net.minecraft.world
Interface HeightLimitView
- All Known Subinterfaces:
BlockRenderView,BlockView,CollisionView,LightSourceView,LunarWorldView,RedstoneView,RegistryWorldView,ServerWorldAccess,StructureWorldAccess,WorldAccess,WorldView
- All Known Implementing Classes:
Chunk,ChunkCache,ChunkRegion,ChunkRendererRegion,ClientWorld,EmptyBlockRenderView,EmptyBlockView,EmptyChunk,FallingBlockEntityRenderState,ProtoChunk,ServerWorld,World,WorldChunk,WrapperProtoChunk
public interface HeightLimitView
A view with a height limit specification.
- Mappings:
Namespace Name named net/minecraft/world/HeightLimitViewintermediary net/minecraft/class_5539official dkl
-
Method Summary
Modifier and TypeMethodDescriptiondefault intReturns the number of sections, vertically, within this view.static HeightLimitViewcreate(int bottomY, int height) default intReturns the bottom section coordinate, inclusive, of this view.intReturns the bottom Y level, or height, inclusive, of this view.intdefault intgetSectionIndex(int y) Returns a zero-based section index to which theylevel belongs.default intReturns the top section coordinate, exclusive, of this view.default intReturns the top Y level, or height, inclusive, of this view.default booleanisInHeightLimit(int y) default booleanisOutOfHeightLimit(int y) Checks ifyis out of the height limit of this view.default booleanChecks ifposis out of the height limit of this view.default intsectionCoordToIndex(int coord) Converts a section coordinate to a zero-based section index.default intsectionIndexToCoord(int index) Converts a zero-based section index to a section coordinate.
-
Method Details
-
getHeight
int getHeight()Returns the difference in the minimum and maximum height.This is the number of blocks that can be modified in any vertical column within the view, or the vertical size, in blocks, of the view.
- Returns:
- the difference in the minimum and maximum height
- See Also:
- Mappings:
Namespace Name Mixin selector named getHeightLnet/minecraft/world/HeightLimitView;getHeight()Iintermediary method_31605Lnet/minecraft/class_5539;method_31605()Iofficial L_Ldkl;L_()I
-
getBottomY
int getBottomY()Returns the bottom Y level, or height, inclusive, of this view.- See Also:
- Mappings:
Namespace Name Mixin selector named getBottomYLnet/minecraft/world/HeightLimitView;getBottomY()Iintermediary method_31607Lnet/minecraft/class_5539;method_31607()Iofficial K_Ldkl;K_()I
-
getTopYInclusive
default int getTopYInclusive()Returns the top Y level, or height, inclusive, of this view.- See Also:
- Implementation Note:
- This implementation sums up the bottom Y and the height, then subtracts 1.
- Mappings:
Namespace Name Mixin selector named getTopYInclusiveLnet/minecraft/world/HeightLimitView;getTopYInclusive()Iintermediary method_31600Lnet/minecraft/class_5539;method_31600()Iofficial aoLdkl;ao()I
-
countVerticalSections
default int countVerticalSections()Returns the number of sections, vertically, within this view.- Returns:
- the number of sections
- See Also:
- Mappings:
Namespace Name Mixin selector named countVerticalSectionsLnet/minecraft/world/HeightLimitView;countVerticalSections()Iintermediary method_32890Lnet/minecraft/class_5539;method_32890()Iofficial apLdkl;ap()I
-
getBottomSectionCoord
default int getBottomSectionCoord()Returns the bottom section coordinate, inclusive, of this view.- Returns:
- the bottom section coordinate
- See Also:
- Implementation Note:
- This implementation passes the bottom Y
through
ChunkSectionPos.getSectionCoord(int). - Mappings:
Namespace Name Mixin selector named getBottomSectionCoordLnet/minecraft/world/HeightLimitView;getBottomSectionCoord()Iintermediary method_32891Lnet/minecraft/class_5539;method_32891()Iofficial aqLdkl;aq()I
-
getTopSectionCoord
default int getTopSectionCoord()Returns the top section coordinate, exclusive, of this view.- Returns:
- the top section coordinate
- See Also:
- Implementation Note:
- This implementation passes the top Y
through
ChunkSectionPos.getSectionCoord(int). - Mappings:
Namespace Name Mixin selector named getTopSectionCoordLnet/minecraft/world/HeightLimitView;getTopSectionCoord()Iintermediary method_31597Lnet/minecraft/class_5539;method_31597()Iofficial arLdkl;ar()I
-
isInHeightLimit
default boolean isInHeightLimit(int y) - See Also:
- Mappings:
Namespace Name Mixin selector named isInHeightLimitLnet/minecraft/world/HeightLimitView;isInHeightLimit(I)Zintermediary method_62871Lnet/minecraft/class_5539;method_62871(I)Zofficial dLdkl;d(I)Z
-
isOutOfHeightLimit
Checks ifposis out of the height limit of this view.- Parameters:
pos- the position to check- Returns:
trueifposis out of bounds,falseotherwise.- See Also:
- Mappings:
Namespace Name Mixin selector named isOutOfHeightLimitLnet/minecraft/world/HeightLimitView;isOutOfHeightLimit(Lnet/minecraft/util/math/BlockPos;)Zintermediary method_31606Lnet/minecraft/class_5539;method_31606(Lnet/minecraft/class_2338;)Zofficial tLdkl;t(Liw;)Z
-
isOutOfHeightLimit
default boolean isOutOfHeightLimit(int y) Checks ifyis out of the height limit of this view.yis out of bounds if it's lower than the bottom or higher than the top.- Parameters:
y- the Y level to check- Returns:
trueifyis out of bounds,falseotherwise.- Mappings:
Namespace Name Mixin selector named isOutOfHeightLimitLnet/minecraft/world/HeightLimitView;isOutOfHeightLimit(I)Zintermediary method_31601Lnet/minecraft/class_5539;method_31601(I)Zofficial eLdkl;e(I)Z
-
getSectionIndex
default int getSectionIndex(int y) Returns a zero-based section index to which theylevel belongs.- Returns:
- a zero-based index
- Mappings:
Namespace Name Mixin selector named getSectionIndexLnet/minecraft/world/HeightLimitView;getSectionIndex(I)Iintermediary method_31602Lnet/minecraft/class_5539;method_31602(I)Iofficial fLdkl;f(I)I
-
sectionCoordToIndex
default int sectionCoordToIndex(int coord) Converts a section coordinate to a zero-based section index.- Parameters:
coord- the section coordinate- Returns:
- a zero-based index
- See Also:
- Mappings:
Namespace Name Mixin selector named sectionCoordToIndexLnet/minecraft/world/HeightLimitView;sectionCoordToIndex(I)Iintermediary method_31603Lnet/minecraft/class_5539;method_31603(I)Iofficial gLdkl;g(I)I
-
sectionIndexToCoord
default int sectionIndexToCoord(int index) Converts a zero-based section index to a section coordinate.- Parameters:
index- the zero-based section index- Returns:
- a section coordinate
- See Also:
- Mappings:
Namespace Name Mixin selector named sectionIndexToCoordLnet/minecraft/world/HeightLimitView;sectionIndexToCoord(I)Iintermediary method_31604Lnet/minecraft/class_5539;method_31604(I)Iofficial hLdkl;h(I)I
-
create
- Mappings:
Namespace Name Mixin selector named createLnet/minecraft/world/HeightLimitView;create(II)Lnet/minecraft/world/HeightLimitView;intermediary method_39034Lnet/minecraft/class_5539;method_39034(II)Lnet/minecraft/class_5539;official eLdkl;e(II)Ldkl;
-