Vec3:sub

Subtracts a vector or a number from the vector.

v = Vec3:sub(u)

Arguments

NameTypeDescription
uVec3The other vector.

Returns

NameTypeDescription
vVec3The original vector.

v = Vec3:sub(x)

Arguments

NameTypeDescription
xnumberA number to subtract from each component.

Returns

NameTypeDescription
vVec3The original vector.

See also