UNPKG

hytopia

Version:

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

62 lines (30 loc) 1.01 kB
<!-- Do not edit this file. It is automatically generated by API Documenter. --> [Home](./index.md) &gt; [server](./server.md) &gt; [EntityModelAnimation](./server.entitymodelanimation.md) &gt; [setPlaybackRate](./server.entitymodelanimation.setplaybackrate.md) ## EntityModelAnimation.setPlaybackRate() method Sets the playback rate of the entity model animation. **Signature:** ```typescript setPlaybackRate(playbackRate: number): void; ``` ## Parameters <table><thead><tr><th> Parameter </th><th> Type </th><th> Description </th></tr></thead> <tbody><tr><td> playbackRate </td><td> number </td><td> The playback rate of the entity model animation. \*\*Side effects:\*\* Emits `EntityModelAnimationEvent.SET_PLAYBACK_RATE` when spawned. \*\*Category:\*\* Entities </td></tr> </tbody></table> **Returns:** void ## Remarks A positive value plays the animation forward, a negative value plays it in reverse. Defaults to 1.