Skip to content

Commit

Permalink
Fix off by one error in calculating storage array size in Chunk
Browse files Browse the repository at this point in the history
  • Loading branch information
Barteks2x committed Nov 11, 2023
1 parent 7253e3c commit d7b6a89
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ private void cubicChunkColumn_construct(World world, int x, int z, CallbackInfo
@ModifyConstant(method = "<init>(Lnet/minecraft/world/World;II)V", constant = @Constant(intValue = 16))
private int modifySectionArrayLength(int sixteen, World worldIn, int x, int z) {
IMinMaxHeight y = (IMinMaxHeight) worldIn;
return Coords.blockToCube(y.getMaxHeight()) - Coords.blockToCube(y.getMinHeight()) + 1;
return Coords.blockToCube(y.getMaxHeight()) - Coords.blockToCube(y.getMinHeight());
}

@Redirect(method = "<init>(Lnet/minecraft/world/World;Lnet/minecraft/world/chunk/ChunkPrimer;II)V",
Expand Down

0 comments on commit d7b6a89

Please sign in to comment.