lovr.headset.getVelocity

Edit

Returns the current linear velocity of a device, in meters per second.

vx, vy, vz = lovr.headset.getVelocity(device)

Arguments

NameTypeDefaultDescription
deviceDevice'head' The device to get the velocity of.

Returns

NameTypeDescription
vxnumber The x component of the linear velocity.
vynumber The y component of the linear velocity.
vznumber The z component of the linear velocity.

Notes

If the device isn't tracked, all zeroes will be returned.

See also