Vector3D

case
class Vector3D(x: Double, y: Double, z: Double)

An abstract vector of a 3-dimensional Euclidean space.

Companion
object
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any

Value members

Concrete methods

def add(another: Vector3D): Vector3D
def length: Double
def lengthSquared: Double
def minus(another: Vector3D): Vector3D
def multiply(l: Double): Vector3D

Calculate the normalized vector that points to the same direction as this vector. Requires that this vector is nonzero.

Calculate the normalized vector that points to the same direction as this vector. Requires that this vector is nonzero.

def pitch: Double

Pitch of an entity whose face direction is collinear to this vector. Requires that this vector is nonzero.

Pitch of an entity whose face direction is collinear to this vector. Requires that this vector is nonzero.

See https://wiki.vg/index.php?title=Protocol&oldid=16681#Player_Rotation for details.

def yaw: Double

Yaw of an entity whose face direction is collinear to this vector. Requires that this vector has nonzero projection onto XZ plane.

Yaw of an entity whose face direction is collinear to this vector. Requires that this vector has nonzero projection onto XZ plane.

See https://wiki.vg/index.php?title=Protocol&oldid=16681#Player_Rotation for details.

Inherited methods

def productElementNames: Iterator[String]
Inherited from
Product
def productIterator: Iterator[Any]
Inherited from
Product