findAnimationByName method

Animation? findAnimationByName(
  1. String name
)

Searches for an Animation by name.

Returns null if no animation with the specified name is found.

To enumerate all animations on this node, use parsedAnimations. Animations can be instantiated on a nodes using createAnimationClip.

Implementation

Animation? findAnimationByName(String name) {
  return _animations.firstWhereOrNull((element) => element.name == name);
}