Class BuildGeometry

java.lang.Object
tschipp.linear.build.BuildGeometry

public final class BuildGeometry extends Object
Which positions a drag from start to end covers, for each BuildMode. Doesn't check whether blocks can actually be placed there.
  • line_3_axes: a straight line in any direction.
  • line_2_axes: the same, but the axis that changes least stays at the start's value.
  • line_1_axis: only along the axis that changes most.
  • wall_2_axes: a wall along the horizontal axis that changes most, or a floor if start and end are at the same height.
  • wall_3_axes: the same, but the wall can run diagonally.
  • circle_2_axes: a ring around the start through the end, in the plane of the two axes that change most.
  • sphere_3_axes: a hollow sphere around the start through the end.
Ties between axes prefer horizontal over Y, and X over Z.
  • Method Details

    • positions

      public static List<net.minecraft.core.BlockPos> positions(BuildMode mode, net.minecraft.core.BlockPos start, net.minecraft.core.BlockPos end)
      Every position the drag covers, each once.