ReferenceScripting APIMotionBeat
MotionBeat
interfaceThe beat of what's playing.
| Name | MotionBeat |
|---|---|
| Kind | interface |
| Script reaches it as | MotionScene.beat |
| Since | 0.3 |
Syntax
interface MotionBeat { … }Properties
| Name | Type | Description |
|---|---|---|
pulseproperty | readonly number | A pulse on each beat: 1 as it lands, falling to 0. |
countproperty | readonly number | How many beats there have been. |
sinceproperty | readonly number | Seconds since the last beat. |
bpmproperty | readonly number | Beats a minute, from the last few beats; 0 until there have been some. |
onsetproperty | readonly boolean | True just as a beat lands (within 0.15 seconds of it). |
Notes from the community
Written by creators and checked by the docs' editors. Not part of Motion's official reference.