diff --git a/mappings/net/minecraft/world/PortalUtil.mapping b/mappings/net/minecraft/world/BlockLocating.mapping similarity index 66% rename from mappings/net/minecraft/world/PortalUtil.mapping rename to mappings/net/minecraft/world/BlockLocating.mapping index 8317dd100f..b5c374ece9 100644 --- a/mappings/net/minecraft/world/PortalUtil.mapping +++ b/mappings/net/minecraft/world/BlockLocating.mapping @@ -1,4 +1,5 @@ -CLASS net/minecraft/class_5459 net/minecraft/world/PortalUtil +CLASS net/minecraft/class_5459 net/minecraft/world/BlockLocating + COMMENT A few utilities to find block positions matching certain conditions. METHOD method_30574 getLargestRectangle (Lnet/minecraft/class_2338;Lnet/minecraft/class_2350$class_2351;ILnet/minecraft/class_2350$class_2351;ILjava/util/function/Predicate;)Lnet/minecraft/class_5459$class_5460; COMMENT Gets the largest rectangle of blocks along two axes for which all blocks meet a predicate. COMMENT Used for getting rectangles of Nether portal blocks. @@ -7,7 +8,11 @@ CLASS net/minecraft/class_5459 net/minecraft/world/PortalUtil ARG 2 primaryMaxBlocks ARG 3 secondaryAxis ARG 4 secondaryMaxBlocks + ARG 5 predicate METHOD method_30575 moveWhile (Ljava/util/function/Predicate;Lnet/minecraft/class_2338$class_2339;Lnet/minecraft/class_2350;I)I + ARG 0 predicate + ARG 1 pos + ARG 2 direction ARG 3 max METHOD method_30576 findLargestRectangle ([I)Lcom/mojang/datafixers/util/Pair; COMMENT Finds the largest rectangle within a histogram, where the vertical bars each have @@ -30,6 +35,23 @@ CLASS net/minecraft/class_5459 net/minecraft/world/PortalUtil COMMENT Rectangle in Histogram - LeetCode ARG 0 heights COMMENT the heights of bars in the histogram + METHOD method_34851 findColumnEnd (Lnet/minecraft/class_1922;Lnet/minecraft/class_2338;Lnet/minecraft/class_2248;Lnet/minecraft/class_2350;Lnet/minecraft/class_2248;)Ljava/util/Optional; + COMMENT Finds an end to a block column starting from {@code pos} extending in {@code + COMMENT direction}. Within the column, the block states must be of {@code intermediateBlock} + COMMENT and the ending block state, whose position is returned, must be of {@code endBlock}. + COMMENT + COMMENT @return the end position of the block column where a {@code endBlock} lays, or + COMMENT an empty optional if no such column exists + ARG 0 world + COMMENT the world the column is in + ARG 1 pos + COMMENT the starting position of the column + ARG 2 intermediateBlock + COMMENT the blocks that the column must be of, excluding the end + ARG 3 direction + COMMENT the direction which the column extends to + ARG 4 endBlock + COMMENT the ending block of the column CLASS class_5460 Rectangle FIELD field_25936 lowerLeft Lnet/minecraft/class_2338; FIELD field_25937 width I