UNPKG

hytopia

Version:

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

70 lines (33 loc) 929 B
<!-- Do not edit this file. It is automatically generated by API Documenter. --> [Home](./index.md) &gt; [server](./server.md) &gt; [Collider](./server.collider.md) &gt; [addToSimulation](./server.collider.addtosimulation.md) ## Collider.addToSimulation() method Adds the collider to the simulation. **Signature:** ```typescript addToSimulation(simulation: Simulation, parentRigidBody?: RigidBody): void; ``` ## Parameters <table><thead><tr><th> Parameter </th><th> Type </th><th> Description </th></tr></thead> <tbody><tr><td> simulation </td><td> [Simulation](./server.simulation.md) </td><td> The simulation to add the collider to. </td></tr> <tr><td> parentRigidBody </td><td> [RigidBody](./server.rigidbody.md) </td><td> _(Optional)_ The parent rigid body of the collider. </td></tr> </tbody></table> **Returns:** void