public class BoundingBox
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
float |
maxX |
float |
maxY |
float |
maxZ |
float |
minX |
float |
minY |
float |
minZ |
Constructor and Description |
---|
BoundingBox(float minX,
float minY,
float minZ,
float maxX,
float maxY,
float maxZ) |
BoundingBox(org.bukkit.util.Vector min,
org.bukkit.util.Vector max) |
Modifier and Type | Method and Description |
---|---|
BoundingBox |
add(float x,
float y,
float z) |
BoundingBox |
add(float minX,
float minY,
float minZ,
float maxX,
float maxY,
float maxZ) |
BoundingBox |
add(org.bukkit.util.Vector vector) |
BoundingBox |
addCoord(float x,
float y,
float z) |
double |
calculateXOffset(BoundingBox other,
double offsetX)
if instance and the argument bounding boxes overlap in the Y and Z dimensions, calculate the offset between them
in the X dimension.
|
double |
calculateYOffset(BoundingBox other,
double offsetY)
if instance and the argument bounding boxes overlap in the X and Z dimensions, calculate the offset between them
in the Y dimension.
|
double |
calculateZOffset(BoundingBox other,
double offsetZ)
if instance and the argument bounding boxes overlap in the Y and X dimensions, calculate the offset between them
in the Z dimension.
|
boolean |
collides(java.lang.Object other) |
boolean |
collides(org.bukkit.util.Vector vector) |
boolean |
collidesHorizontally(java.lang.Object other) |
boolean |
collidesHorizontally(org.bukkit.util.Vector vector) |
boolean |
collidesVertically(java.lang.Object other) |
boolean |
collidesVertically(org.bukkit.util.Vector vector) |
java.util.List<org.bukkit.block.Block> |
getAllBlocks(org.bukkit.entity.Player player) |
java.util.List<BoundingBox> |
getCollidingBlockBoxes(org.bukkit.entity.Player player) |
java.util.List<org.bukkit.block.Block> |
getCollidingBlocks(org.bukkit.entity.Player player) |
org.bukkit.util.Vector |
getMaximum() |
org.bukkit.util.Vector |
getMinimum() |
BoundingBox |
grow(float x,
float y,
float z) |
boolean |
inBlock(org.bukkit.entity.Player player) |
boolean |
intersectsWithBox(java.lang.Object other) |
boolean |
intersectsWithBox(org.bukkit.util.Vector vector) |
BoundingBox |
shrink(float x,
float y,
float z) |
BoundingBox |
subtract(float minX,
float minY,
float minZ,
float maxX,
float maxY,
float maxZ) |
java.lang.Object |
toAxisAlignedBB() |
java.lang.String |
toString() |
public float minX
public float minY
public float minZ
public float maxX
public float maxY
public float maxZ
public BoundingBox(float minX, float minY, float minZ, float maxX, float maxY, float maxZ)
public BoundingBox(org.bukkit.util.Vector min, org.bukkit.util.Vector max)
public BoundingBox add(float x, float y, float z)
public BoundingBox add(org.bukkit.util.Vector vector)
public BoundingBox grow(float x, float y, float z)
public BoundingBox shrink(float x, float y, float z)
public BoundingBox add(float minX, float minY, float minZ, float maxX, float maxY, float maxZ)
public BoundingBox subtract(float minX, float minY, float minZ, float maxX, float maxY, float maxZ)
public boolean intersectsWithBox(org.bukkit.util.Vector vector)
public java.util.List<BoundingBox> getCollidingBlockBoxes(org.bukkit.entity.Player player)
public org.bukkit.util.Vector getMinimum()
public org.bukkit.util.Vector getMaximum()
public java.util.List<org.bukkit.block.Block> getCollidingBlocks(org.bukkit.entity.Player player)
public java.util.List<org.bukkit.block.Block> getAllBlocks(org.bukkit.entity.Player player)
public boolean inBlock(org.bukkit.entity.Player player)
public boolean intersectsWithBox(java.lang.Object other)
public boolean collides(org.bukkit.util.Vector vector)
public boolean collides(java.lang.Object other)
public boolean collidesHorizontally(org.bukkit.util.Vector vector)
public boolean collidesHorizontally(java.lang.Object other)
public boolean collidesVertically(org.bukkit.util.Vector vector)
public boolean collidesVertically(java.lang.Object other)
public double calculateXOffset(BoundingBox other, double offsetX)
public double calculateYOffset(BoundingBox other, double offsetY)
public double calculateZOffset(BoundingBox other, double offsetZ)
public BoundingBox addCoord(float x, float y, float z)
public java.lang.Object toAxisAlignedBB()
public java.lang.String toString()
toString
in class java.lang.Object