playMaker
Home
Store
Showcase
Tutorials
Forums
Manual
Wiki
About Us
Playmaker Forum
Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email
?
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
News:
Join our
Discord Channel
Home
Help
Search
Login
Register
Playmaker Forum
»
PlayMaker Help & Tips
»
PlayMaker Help
(Moderator:
600
) »
Setting the current time of an animation with a float
« previous
next »
Print
Pages: [
1
]
Go Down
Author
Topic: Setting the current time of an animation with a float (Read 2152 times)
frogwise
Playmaker Newbie
Posts: 49
Setting the current time of an animation with a float
«
on:
May 02, 2016, 01:49:26 AM »
Hey guys I will try to be as clear as possible with this:
I have a UI element that I am animating with an Animator and an Animation.
I would like a float variable to drive the point at which that animation is at.
So basically, the animation doesnt "Play". Its "current time" simple just gets set to the float variable I am feeding it (which is normalized.)
How can I do this?
Logged
jeanfabre
Administrator
Hero Member
Posts: 15500
Official Playmaker Support
Re: Setting the current time of an animation with a float
«
Reply #1 on:
May 02, 2016, 02:19:20 AM »
Hi,
The only technic I know is to use "animatorPlay" action from the
Animator package
form the
Ecosystem
.
This allows you to play an animation and define the time, if you run this action everyframe, you effectively control the timing.
have you tried this?
Bye,
Jean
Logged
frogwise
Playmaker Newbie
Posts: 49
Re: Setting the current time of an animation with a float
«
Reply #2 on:
May 02, 2016, 02:20:32 AM »
I was just about to reply to my own topic but you beat me to it!
So yes, essentially, I want to use Animator Play. However, there is no option to do this action Every Frame... otherwise, it would be perfect.
Logged
jeanfabre
Administrator
Hero Member
Posts: 15500
Official Playmaker Support
Re: Setting the current time of an animation with a float
«
Reply #3 on:
May 02, 2016, 02:46:45 AM »
Hi,
Good point. You can loop back when desired, but I have added the option now. simply redownload the
package
from the
Ecosystem
, and AnimatorPlay will now have the option.
Bye,
Jean
Logged
frogwise
Playmaker Newbie
Posts: 49
Re: Setting the current time of an animation with a float
«
Reply #4 on:
May 02, 2016, 03:30:15 AM »
Excellent! Thank you.
Curious - is it rather expensive to be doing this action every frame? This is for Android.
Logged
jeanfabre
Administrator
Hero Member
Posts: 15500
Official Playmaker Support
Re: Setting the current time of an animation with a float
«
Reply #5 on:
May 06, 2016, 01:54:18 AM »
Hi,
for one character no, for all ennemies ( dozens ) probably...
the difficult you may face is issues with the last few frames of the animation. I know some developer where using this technic and had to use legacy after a while cause the Animator engine would not behave properly when playing too much with time. So make sure you properly test your character behavior before adopting this for everything.
Bye,
Jean
Logged
Print
Pages: [
1
]
Go Up
« previous
next »
Playmaker Forum
»
PlayMaker Help & Tips
»
PlayMaker Help
(Moderator:
600
) »
Setting the current time of an animation with a float