hytopia
Version:
The HYTOPIA SDK makes it easy for developers to create massively multiplayer games using JavaScript or TypeScript.
56 lines (27 loc) • 766 B
Markdown
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[Home](./index.md) > [server](./server.md) > [Vector3](./server.vector3.md) > [distance](./server.vector3.distance.md)
## Vector3.distance() method
Calculates the distance between the current vector and another vector.
**Signature:**
```typescript
distance(vector3: Vector3): number;
```
## 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 calculate the distance to.
</td></tr>
</tbody></table>
**Returns:**
number
The distance between the two vectors.