Class GridAlignedBB

java.lang.Object
com.jozufozu.flywheel.util.box.GridAlignedBB
All Implemented Interfaces:
ImmutableBox

public class GridAlignedBB extends Object implements ImmutableBox
  • Constructor Details

    • GridAlignedBB

      public GridAlignedBB()
    • GridAlignedBB

      public GridAlignedBB(int minX, int minY, int minZ, int maxX, int maxY, int maxZ)
  • Method Details

    • ofRadius

      public static GridAlignedBB ofRadius(int radius)
    • from

      public static GridAlignedBB from(net.minecraft.world.phys.AABB aabb)
    • from

      public static GridAlignedBB from(net.minecraft.core.SectionPos pos)
    • from

      public static GridAlignedBB from(net.minecraft.core.BlockPos start, net.minecraft.core.BlockPos end)
    • from

      public static GridAlignedBB from(net.minecraft.core.BlockPos pos)
    • from

      public static GridAlignedBB from(int sectionX, int sectionZ)
    • containingAll

      public static ImmutableBox containingAll(Collection<net.minecraft.core.BlockPos> positions)
    • fixMinMax

      public void fixMinMax()
    • translate

      public void translate(net.minecraft.core.Vec3i by)
    • translate

      public void translate(int x, int y, int z)
    • mirrorAbout

      public void mirrorAbout(net.minecraft.core.Direction.Axis axis)
    • nextPowerOf2Centered

      public void nextPowerOf2Centered()
      Grow this bounding box to have power of 2 side length, scaling from the center.
    • nextPowerOf2

      public void nextPowerOf2()
      Grow this bounding box to have power of 2 side lengths, scaling from the minimum coords.
    • grow

      public void grow(int s)
    • grow

      public void grow(int x, int y, int z)
    • intersectAssign

      public void intersectAssign(ImmutableBox other)
    • unionAssign

      public void unionAssign(ImmutableBox other)
    • unionAssign

      public void unionAssign(net.minecraft.world.phys.AABB other)
    • assign

      public void assign(net.minecraft.world.phys.AABB other)
    • assign

      public void assign(ImmutableBox other)
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • getMinX

      public int getMinX()
      Specified by:
      getMinX in interface ImmutableBox
    • getMinY

      public int getMinY()
      Specified by:
      getMinY in interface ImmutableBox
    • getMinZ

      public int getMinZ()
      Specified by:
      getMinZ in interface ImmutableBox
    • getMaxX

      public int getMaxX()
      Specified by:
      getMaxX in interface ImmutableBox
    • getMaxY

      public int getMaxY()
      Specified by:
      getMaxY in interface ImmutableBox
    • getMaxZ

      public int getMaxZ()
      Specified by:
      getMaxZ in interface ImmutableBox
    • setMinX

      public GridAlignedBB setMinX(int minX)
    • setMinY

      public GridAlignedBB setMinY(int minY)
    • setMinZ

      public GridAlignedBB setMinZ(int minZ)
    • setMaxX

      public GridAlignedBB setMaxX(int maxX)
    • setMaxY

      public GridAlignedBB setMaxY(int maxY)
    • setMaxZ

      public GridAlignedBB setMaxZ(int maxZ)
    • assign

      public GridAlignedBB assign(net.minecraft.core.BlockPos start, net.minecraft.core.BlockPos end)
    • setMax

      public GridAlignedBB setMax(net.minecraft.core.Vec3i v)
    • setMin

      public GridAlignedBB setMin(net.minecraft.core.Vec3i v)
    • setMax

      public GridAlignedBB setMax(int x, int y, int z)
    • setMin

      public GridAlignedBB setMin(int x, int y, int z)
    • sizeX

      public int sizeX()
      Specified by:
      sizeX in interface ImmutableBox
    • sizeY

      public int sizeY()
      Specified by:
      sizeY in interface ImmutableBox
    • sizeZ

      public int sizeZ()
      Specified by:
      sizeZ in interface ImmutableBox
    • empty

      public boolean empty()
      Specified by:
      empty in interface ImmutableBox
    • sameAs

      public boolean sameAs(ImmutableBox other)
      Specified by:
      sameAs in interface ImmutableBox
    • sameAs

      public boolean sameAs(net.minecraft.world.phys.AABB other)
      Specified by:
      sameAs in interface ImmutableBox
    • intersect

      public GridAlignedBB intersect(ImmutableBox other)
      Specified by:
      intersect in interface ImmutableBox
    • union

      public ImmutableBox union(ImmutableBox other)
      Specified by:
      union in interface ImmutableBox
    • contains

      public boolean contains(ImmutableBox other)
      Specified by:
      contains in interface ImmutableBox
    • intersects

      public boolean intersects(int minX, int minY, int minZ, int maxX, int maxY, int maxZ)
      Specified by:
      intersects in interface ImmutableBox
    • forEachContained

      public void forEachContained(CoordinateConsumer func)
      Specified by:
      forEachContained in interface ImmutableBox
    • toAABB

      public net.minecraft.world.phys.AABB toAABB()
      Specified by:
      toAABB in interface ImmutableBox
    • copy

      public GridAlignedBB copy()
      Specified by:
      copy in interface ImmutableBox
    • toString

      public String toString()
      Overrides:
      toString in class Object