1
0
Fork 0
mirror of https://github.com/ninjamuffin99/Funkin.git synced 2024-12-23 05:37:38 +00:00

Tinkering with atlassprite

This commit is contained in:
CheemsAndFriends 2024-09-11 20:05:39 +02:00
parent 17a48bfc2b
commit c81f041695

View file

@ -169,19 +169,6 @@ class FlxAtlasSprite extends FlxAnimate
}
}
anim.onComplete.removeAll();
anim.onComplete.add(function() {
if (loop)
{
this.anim.play(id, restart, false, startFrame);
this.currentAnimation = id;
}
else
{
onAnimationComplete.dispatch(id);
}
});
looping = loop;
// Prevent other animations from playing if `ignoreOther` is true.
@ -191,7 +178,7 @@ class FlxAtlasSprite extends FlxAnimate
// goToFrameLabel(id);
trace('Playing animation $id');
// Only call goToFrameLabel if there is a frame label with that name. This prevents annoying warnings!
if (getFrameLabelNames().indexOf(id) != -1)
if (getLabelIndex(id) != -1)
{
goToFrameLabel(id);
fr = anim.getFrameLabel(id);