-
Notifications
You must be signed in to change notification settings - Fork 3
1. Custom Events
This page documents custom events and their usage.
Custom events events can be created using the following syntax.
new AnimateTrack(4);This creates a new AnimateTrack object with a time value of
4
.You can add properties to it, such as
track: "trackName"
. Properties are added using methods in the following way.new AnimateTrack(4, { track: "trackName", duration: 1, easing: ease.Out.Sine, scale: [ [2, 2, 2, 0], [1, 1, 1, 1] ] })A custom event is pushed by calling the
push()
method. Like so.new AnimateTrack(4, { track: "trackName", duration: 1, easing: ease.Out.Sine, scale: [ [2, 2, 2, 0], [1, 1, 1, 1] ] }).push();This is the base syntax for all objects/events.
Alternate syntax
You can also use an alternative syntax by doing the following:const scaleAnim = new AnimateTrack(); scaleAnim.time = 4; scaleAnim.data.track = "trackName"; scaleAnim.data.duration = 1; scaleAnim.data.easing = ease.Out.Sine; scaleAnim.data.scale = [ [2, 2, 2, 0], [1, 1, 1, 1] ];
AnimateTrack events are created with the following.
new AnimateTrack(time, data)You can also use a snippet to create one by typing
animTrack
and pressingenter
.
track: string|string[]
Assigns the track of the animation.easing: string
Assigns the easing used for the animation.duration: number
Assigns the animation duration in beats.position: vec3|vec3[]
Assigns the position animation.localPosition: vec3|vec3[]
Assigns the localPosition animation.rotation: vec3|vec3[]
Assigns the rotation animation.localRotation: vec3|vec3[]
Assigns the localRotation animation.scale: vec3|vec3[]
Assigns the scale animation.color: vec4|vec4[]
Assigns the color animation.dissolve: vec1|vec1[]
Assigns the dissolve animation.dissolveArrow: vec1|vec1[]
Assigns the dissolveArrow animation.interactable: vec1|vec1[]
Assigns the interactable animation.time: vec1|vec1[]
Assigns the time animation. (Try to avoid using this)
AssignPathAnimation events are created with the following.
new AssignPathAnimation(time, data)You can also use a snippet to create one by typing
pathAnim
and pressingenter
.
track: string|string[]
Assigns thetrack
of the animation.easing: string
Assigns theeasing
used for the animation.position: vec3|vec3[]
Assigns theposition
animation.definitePosition: vec3|vec3[]
Assigns thedefinitePosition
animation.rotation: vec3|vec3[]
Assigns therotation
animation.scale: vec3|vec3[]
Assigns thescale
animation.color: vec4|vec4[]
Assigns thecolor
animation.dissolve: vec1|vec1[]
Assigns thedissolve
animation.dissolveArrow: vec1|vec1[]
Assigns thedissolveArrow
animation.interactable: vec1|vec1[]
Assigns theinteractable
animation.
AssignPlayerToTrack events are created with the following.
new AssignPlayerToTrack(time, track)You can also use a snippet to create one by typing
playerTrack
and pressingenter
.
track: string
Assigns the track for the player.
AssignTrackParent events are created with the following.
new AssignTrackParent(time, data)You can also use a snippet to create one by typing
trackParent
and pressingenter
.
parentTrack: string
Assigns the parent track for the children tracks.childrenTracks: string[]
Assigns the children for the parent track.
Functions
- Note Effects
- Wall Effects
- Other Effects