https://kotlinlang.org logo
#korge
Title
# korge
p

Pal Matolay

06/14/2020, 11:36 PM
Can I stop the sprite animation in the end? (like
endFrame
instead of `startFrame`or similar) (Because by default it goes back to the first frame at the end of the animation.)
d

Deactivated User

06/15/2020, 12:00 AM
uhm, that's probably a bug or something. Maybe you can try as a workaround:
Copy code
sprite.onAnimationCompleted {
     setFrame(animation.size - 1)
}
@Nico
p

Pal Matolay

06/15/2020, 12:14 AM
Thank you, I can work with that. More info about the above mentioned behaviour: When I playing the animation reversed, then it stop at the first frame. So it working as I excepted. Only the normal way is doing that. (Sorry for my english, I’m extremely tired.)
d

Deactivated User

06/15/2020, 12:21 AM
No problem. I have created an issue. Thanks for reporting! https://github.com/korlibs/korge/issues/216
👍 1
p

Pal Matolay

06/15/2020, 2:34 AM
Maybe the engine has issue with stop the music. Or I’m doing something wrongly. But it reset when the new scene loaded.
I’m skipping now, but FYI (I also need to look closer)
n

Nico

06/15/2020, 4:41 AM
We don’t have anything like
endframe
. But we should def. add that
👍 1
p

Pal Matolay

06/15/2020, 8:08 AM
Regarding to the music issue. I was just ignorant. But it was all fine after I found the way. 🙌
9 Views