UNPKG

hytopia

Version:

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

72 lines (34 loc) 932 B
<!-- Do not edit this file. It is automatically generated by API Documenter. --> [Home](./index.md) &gt; [server](./server.md) &gt; [Vector3](./server.vector3.md) &gt; [scaleAndAdd](./server.vector3.scaleandadd.md) ## Vector3.scaleAndAdd() method Adds 2 vectors together after scaling the provided vector by a scalar value. **Signature:** ```typescript scaleAndAdd(vector3: Vector3, scale: number): Vector3; ``` ## Parameters <table><thead><tr><th> Parameter </th><th> Type </th><th> Description </th></tr></thead> <tbody><tr><td> vector3 </td><td> [Vector3](./server.vector3.md) </td><td> The vector to add the scaled vector to. </td></tr> <tr><td> scale </td><td> number </td><td> The scalar value to scale the current vector by. </td></tr> </tbody></table> **Returns:** [Vector3](./server.vector3.md) The current vector.