MCPcopy Create free account
hub / github.com/melonjs/melonJS / isCurrentAnimation

Method isCurrentAnimation

packages/melonjs/src/renderable/sprite.js:588–590  ·  view source on GitHub ↗

* return true if the specified animation is the current one. * @param {string} name - animation id * @returns {boolean} * @example * if (!this.isCurrentAnimation("walk")) { * // do something funny... * }

(name)

Source from the content-addressed store, hash-verified

586 * }
587 */
588 isCurrentAnimation(name) {
589 return this._frameAnim.isCurrentAnimation(name);
590 }
591
592 /**
593 * the names of every animation defined on this sprite (via

Callers 4

sprite.spec.jsFile · 0.45
gltf_model.spec.jsFile · 0.45
texture.spec.jsFile · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected