Skip to content

Instantly share code, notes, and snippets.

@gskachkov
Created October 14, 2018 21:02
Show Gist options
  • Save gskachkov/560952649d3d694a2cebf8572c64fab8 to your computer and use it in GitHub Desktop.
Save gskachkov/560952649d3d694a2cebf8572c64fab8 to your computer and use it in GitHub Desktop.
class Animation {
constructor(options) {
// Called when a new animator is instantiated
// Used to set stuff up for each use of an animator
}
animate(currentTime, effect) {
// currentTime - The current time from the defined timeline
// effect - Group of effects that this animation is working on
// Animation frame logic goes here.
// Usually something to the effect of setting the time of an effect
effect.localTime = currentTime;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment