ReferenceScripting APIMotionPlayOptions
MotionPlayOptions
interfaceHow a sound plays: its volume (0 to 2), pan (-1 left to 1 right), speed (0.25 to 4, faster is higher), whether it loops, its fade in and where it starts (seconds).
| Name | MotionPlayOptions |
|---|---|
| Kind | interface |
| Since | 0.3 |
Syntax
interface MotionPlayOptions { … }Properties
| Name | Type | Description |
|---|---|---|
volumeproperty | number | How loud, 0 to 2 (1 unless given). |
panproperty | number | Where it's heard, -1 left to 1 right (0, the middle, unless given). |
rateproperty | number | How fast it plays, 0.25 to 4 (1 unless given): faster is higher. |
loopproperty | boolean | True to play it round and round until it's stopped. |
fadeInproperty | number | Seconds it takes to fade in from silence (0, at once, unless given; 60 at most). |
offsetproperty | number | Seconds into the sound where it starts (0, its start, unless given). |
Notes from the community
Written by creators and checked by the docs' editors. Not part of Motion's official reference.