Modifier and Type | Field and Description |
---|---|
double |
x |
double |
y |
double |
z |
static Vec3d |
ZERO |
Constructor and Description |
---|
Vec3d(double x,
double y,
double z) |
Vec3d(Vector3f vec) |
Modifier and Type | Method and Description |
---|---|
Vec3d |
add(double x,
double y,
double z) |
Vec3d |
add(Vec3d vec) |
Vec3d |
crossProduct(Vec3d vec) |
double |
distanceTo(Vec3d vec) |
double |
dotProduct(Vec3d vec) |
boolean |
equals(Object o) |
Vec3d |
floorAlongAxes(EnumSet<Direction.Axis> axes) |
static Vec3d |
fromPolar(float pitch,
float yaw) |
static Vec3d |
fromPolar(Vec2f polar) |
double |
getComponentAlongAxis(Direction.Axis axis) |
double |
getX() |
double |
getY() |
double |
getZ() |
int |
hashCode() |
boolean |
isInRange(Position pos,
double radius) |
double |
length() |
double |
lengthSquared() |
Vec3d |
multiply(double mult) |
Vec3d |
multiply(double multX,
double multY,
double multZ) |
Vec3d |
multiply(Vec3d mult) |
Vec3d |
negate() |
Vec3d |
normalize() |
static Vec3d |
of(Vec3i vec) |
static Vec3d |
ofBottomCenter(Vec3i vec) |
static Vec3d |
ofCenter(Vec3i vec) |
static Vec3d |
ofCenter(Vec3i vec,
double deltaY) |
Vec3d |
reverseSubtract(Vec3d vec) |
Vec3d |
rotateX(float angle) |
Vec3d |
rotateY(float angle) |
Vec3d |
rotateZ(float angle) |
double |
squaredDistanceTo(double x,
double y,
double z) |
double |
squaredDistanceTo(Vec3d vec) |
Vec3d |
subtract(double x,
double y,
double z) |
Vec3d |
subtract(Vec3d vec) |
String |
toString() |
static Vec3d |
unpackRgb(int rgb) |
public static final Vec3d ZERO
public final double x
public final double y
public final double z
public Vec3d(double x, double y, double z)
public Vec3d(Vector3f vec)
@Environment(value=CLIENT) public static Vec3d unpackRgb(int rgb)
public Vec3d normalize()
public double dotProduct(Vec3d vec)
public Vec3d subtract(double x, double y, double z)
public Vec3d add(double x, double y, double z)
public boolean isInRange(Position pos, double radius)
public double distanceTo(Vec3d vec)
public double squaredDistanceTo(Vec3d vec)
public double squaredDistanceTo(double x, double y, double z)
public Vec3d multiply(double mult)
@Environment(value=CLIENT) public Vec3d negate()
public Vec3d multiply(double multX, double multY, double multZ)
public double length()
public double lengthSquared()
public Vec3d rotateX(float angle)
public Vec3d rotateY(float angle)
@Environment(value=CLIENT) public Vec3d rotateZ(float angle)
@Environment(value=CLIENT) public static Vec3d fromPolar(float pitch, float yaw)
public Vec3d floorAlongAxes(EnumSet<Direction.Axis> axes)
public double getComponentAlongAxis(Direction.Axis axis)