rive-app / rive-ios

iOS runtime for Rive
MIT License
468 stars 53 forks source link

Animation progress #278

Closed insaite closed 9 months ago

insaite commented 9 months ago

Thank you for such a wonderful tool for working with animations.

I am displaying a metronome animation, and at a certain point in the animation playback, I need to trigger vibration. To do this, I need to know the current playback progress of the animation. Can someone please explain how to obtain the current progress? Thanks!

HayesGordon commented 9 months ago

Hi @insaite

A potentially easier way to achieve this desired outcome is by using the new feature that just launched, Events: https://www.youtube.com/watch?v=Yg8ObnyEhIk

It's a way for the animation to send information to the runtime at the precise point in time needed.

Runtime documentation: https://help.rive.app/runtimes/rive-events

insaite commented 9 months ago

onRiveEventReceived never called