API reference
API reference
Select your platform
No SDKs available
No versions available

WatchedVector3

WatchedVector3

class WatchedVector3(attribute: Vector3Attribute, value: Vector3) : Vector3

Constructors

NameSummary
WatchedVector3
constructor(attribute: Vector3Attribute, value: Vector3)

Properties

NameSummary
x
open override var x: Float
y
open override var y: Float
z
open override var z: Float

Functions

NameSummary
add
inline fun add(v: Vector3): Vector3
Adds two vectors component-wise.
angleBetweenDegrees
fun angleBetweenDegrees(v: Vector3): Float
Calculates the angle between two vectors in degrees.
component1
operator fun component1(): Float
component2
operator fun component2(): Float
component3
operator fun component3(): Float
copy
fun copy(): Vector3
Returns a copy of this vector.
cross
fun cross(other: Vector3): Vector3
Calculates the cross product of two vectors.
distanceTo
fun distanceTo(v: Vector3): Float
Calculates the distance between two vectors.
div
inline operator fun div(v: Float): Vector3
Divides a vector by a scalar.
divide
inline fun divide(v: Float): Vector3
Divides a vector by a scalar.
dot
inline fun dot(v: Vector3): Float
Calculates the dot product of two vectors.
equals
open operator override fun equals(other: Any?): Boolean
hashCode
open override fun hashCode(): Int
length
fun length(): Float
Calculates the length (magnitude) of a vector.
lerp
fun lerp(dest: Vector3, ratio: Float): Vector3
Linearly interpolates between two vectors.
max
fun max(v: Vector3): Vector3
Returns a vector with the maximum components of this vector and another vector.
min
fun min(v: Vector3): Vector3
Returns a vector with the minimum components of this vector and another vector.
minus
inline operator fun minus(v: Vector3): Vector3
Subtracts two vectors component-wise.
multiply
inline fun multiply(v: Vector3): Vector3
Multiplies two vectors component-wise.
inline fun multiply(v: Float): Vector3
Multiplies a vector by a scalar.
negate
inline fun negate(): Vector3
Negates a vector.
normalize
fun normalize(): Vector3
Normalizes a vector to have a length of 1
plus
inline operator fun plus(v: Vector3): Vector3
Adds two vectors component-wise.
setX
fun setX(x: Float): Vector3
setY
fun setY(y: Float): Vector3
setZ
fun setZ(z: Float): Vector3
sub
inline fun sub(v: Vector3): Vector3
Subtracts two vectors component-wise.
times
inline operator fun times(v: Vector3): Vector3
Multiplies two vectors component-wise.
inline operator fun times(v: Float): Vector3
Multiplies a vector by a scalar.
toString
open override fun toString(): String
Returns a string representation of the vector.
unaryMinus
inline operator fun unaryMinus(): Vector3
Negates a vector.
Did you find this page helpful?
Thumbs up icon
Thumbs down icon