UNPKG

hytopia

Version:

The HYTOPIA SDK makes it easy for developers to create massively multiplayer games using JavaScript or TypeScript.

56 lines (27 loc) 864 B
<!-- Do not edit this file. It is automatically generated by API Documenter. --> [Home](./index.md) &gt; [server](./server.md) &gt; [Quaternion](./server.quaternion.md) &gt; [transformVector](./server.quaternion.transformvector.md) ## Quaternion.transformVector() method Rotates the provided vector by the rotation this quaternion represents. This modifies the vector in-place, but also returns the rotated vector. **Signature:** ```typescript transformVector(vector: Vector3): Vector3; ``` ## Parameters <table><thead><tr><th> Parameter </th><th> Type </th><th> Description </th></tr></thead> <tbody><tr><td> vector </td><td> [Vector3](./server.vector3.md) </td><td> the vector to rotate </td></tr> </tbody></table> **Returns:** [Vector3](./server.vector3.md) the rotated vector.