Hello there, I’m trying to get the “play head” position inside an animation in a widget. I would like that when my mouse rolls out of a boutton, the animation plays backward from the actual animation frame position.
This is what I got so far :
In the second “play animation” node, I’d need to hook up something. Does the delta time from the event tick give a valid time for the animation (with some calculation) ?
Is there a node that gives the total size of an animation in a widget ?
Also, I can’t get inside a Hud blue print to draw texts, I would like to check some values, but I have yet no idea how to acess this feature. Is it because I started with a blank project that I can’t access the Hud blue print, or did I miss something here ?
The widget animation objects have a GetStartTime() and a GetEndTime(). Delta time should be fine for determining how much time has passed. Thought it should just play from where it currently is if you’re reversing an already playing animation, without having to do any math if memory serves.
Thank you for your fast reply. I tryed something, but it’s not realy working, even though I reverse the already playing animation, it keeps going on till the end, and never plays backward.
I guess i’m stuck with the GetStartTime() and GetEndTime(), because when I play animation again, it just plays “fresh”, instead of resuming previous playing animation.
Why not use Pause Animation, that will return the current remaining time left on it. Then you could immediately play in reverse from GetEndTime() - PauseTime.
It’s possible that I’ve misinterpreted what’s being asked here, but if I’ve understood, is that you want to play a widget animation when the mouse hovers over a button and reverse that animation when the mouse moves off the button. If that’s the case then your script seems rather convoluted. Here is all I did and it works fine. It will reverse the animation even if it’s only part of the way through the full play time as the UnHovered event is called even while the animation is playing.
Suppose an icon’s background color changes from white to red during the icon is being pressed, and goes back to white when the mouse or touch is released.
I found that Pause Animation node returns “0” when the animation has played forward completely, so I think Branch node is necessary.
I think
Pause Animation node (the same goes for Get Animation Current Time node) should returns end time instead of 0 when the animation has played forward completely. It’s complicating…
Start at Time on Play Animation node should not be reversed when Play Mode is “Reverse”. It’s really complicating…
implementation of timeline node to Widget Blueprint would be really nice!
I tested this and it does NOT appear to work. “StartAtTime” = 0 forces the animation to start at time 0. I want it to just keep playing from where it was in the current animation. However using “get animation current time” doesn’t work because it will incorrectly return “0” if the animation has finished.