LS.Animation.Take Class
Represents a set of animations
Constructor
LS.Animation.Take
()
Item Index
Methods
applyTracks
-
current_time -
last_time -
ignore_interpolation -
weight -
root
For every track, gets the interpolated value between keyframes and applies the value to the property associated with the track locator Locators are in the form of "{NODE_UID}/{COMPONENT_UID}/{property_name}"
Parameters:
-
current_timeNumberthe time of the anim to sample
-
last_timeNumberthis is used for events, we need to know where you were before
-
ignore_interpolationBooleanin case you want to sample the nearest one
-
weightSceneNode[Optional] allows to blend animations with current value (default is 1)
-
rootNumber[Optional] if you want to limit the locator to search inside a node
Returns:
the target where the action was performed
createTrack
-
data
creates a new track from a given data
Parameters:
-
dataObjectin serialized format
Returns:
the track
onlyRotations
()
If this is a transform track it removes translation and scale leaving only rotations
optimizeTracks
()
Optimizes the tracks by changing the Matrix tracks to Trans10 tracks which are way faster and use less space
removeScaling
()
removes scaling in transform tracks
