Uses of Class
com.loohp.limbo.location.Vector
Packages that use Vector
-
Uses of Vector in com.loohp.limbo.location
Fields in com.loohp.limbo.location declared as VectorMethods in com.loohp.limbo.location that return VectorModifier and TypeMethodDescriptionAdds a vector to this oneVector.clone()
Get a new vector.Copies another vectorVector.crossProduct
(Vector o) Calculates the cross product of this vector with another.Divides the vector by another.Vector.getCrossProduct
(Vector o) Calculates the cross product of this vector with another without mutating the original.BlockFace.getDirection()
Gets the normal vector corresponding to this block face.Location.getDirection()
Gets a unit-vector pointing in the direction that this Location is facing.MovingObjectPosition.getLocation()
static Vector
Vector.getMaximum
(Vector v1, Vector v2) Gets the maximum components of two vectors.Vector.getMidpoint
(Vector other) Gets a new midpoint vector between this vector and another.static Vector
Vector.getMinimum
(Vector v1, Vector v2) Gets the minimum components of two vectors.static Vector
Vector.getRandom()
Gets a random vector with components having a random value between 0 and 1.Sets this vector to the midpoint between this vector and another.Vector.multiply
(double m) Performs scalar multiplication, multiplying all components with a scalar.Vector.multiply
(float m) Performs scalar multiplication, multiplying all components with a scalar.Vector.multiply
(int m) Performs scalar multiplication, multiplying all components with a scalar.Multiplies the vector by another.Vector.normalize()
Converts this vector to a unit vector (a vector with length of 1).Vector.rotateAroundAxis
(Vector axis, double angle) Rotates the vector around a given arbitrary axis in 3 dimensional space.Vector.rotateAroundNonUnitAxis
(Vector axis, double angle) Rotates the vector around a given arbitrary axis in 3 dimensional space.Vector.rotateAroundX
(double angle) Rotates the vector around the x axis.Vector.rotateAroundY
(double angle) Rotates the vector around the y axis.Vector.rotateAroundZ
(double angle) Rotates the vector around the z axisVector.setX
(double x) Set the X component.Vector.setX
(float x) Set the X component.Vector.setX
(int x) Set the X component.Vector.setY
(double y) Set the Y component.Vector.setY
(float y) Set the Y component.Vector.setY
(int y) Set the Y component.Vector.setZ
(double z) Set the Z component.Vector.setZ
(float z) Set the Z component.Vector.setZ
(int z) Set the Z component.Subtracts a vector from this one.Location.toVector()
Constructs a newVector
based on this LocationVector.zero()
Zero this vector's components.Methods in com.loohp.limbo.location with parameters of type VectorModifier and TypeMethodDescriptionAdds the location by a vector.Adds a vector to this onefloat
Gets the angle between this vector and another in radians.Copies another vectorVector.crossProduct
(Vector o) Calculates the cross product of this vector with another.double
Get the distance between this vector and another.double
Vector.distanceSquared
(Vector o) Get the squared distance between this vector and another.Divides the vector by another.double
Calculates the dot product of this vector with another.Vector.getCrossProduct
(Vector o) Calculates the cross product of this vector with another without mutating the original.static Vector
Vector.getMaximum
(Vector v1, Vector v2) Gets the maximum components of two vectors.Vector.getMidpoint
(Vector other) Gets a new midpoint vector between this vector and another.static Vector
Vector.getMinimum
(Vector v1, Vector v2) Gets the minimum components of two vectors.boolean
Returns whether this vector is in an axis-aligned bounding box.boolean
Vector.isInSphere
(Vector origin, double radius) Returns whether this vector is within a sphere.Sets this vector to the midpoint between this vector and another.Multiplies the vector by another.Vector.rotateAroundAxis
(Vector axis, double angle) Rotates the vector around a given arbitrary axis in 3 dimensional space.Vector.rotateAroundNonUnitAxis
(Vector axis, double angle) Rotates the vector around a given arbitrary axis in 3 dimensional space.Location.setDirection
(Vector vector) Subtracts the location by a vector.Subtracts a vector from this one.Constructors in com.loohp.limbo.location with parameters of type Vector