Animation Speed controlled by a Property/Speed Relative to Scale

As many of you know I am making a game called T. rex World. In this game, the dinosaurs are supposed to be able to grow up real-time (BTW, I have already figure out this mechanic and have it down pretty well), but what I am having a problem figuring out is how to change the speed of an animation relative the property that controls the age. I don’t want to make 25 different walk animations for every stage of life, so I would rather speed up/ slow down the animation based on the individual’s size.

Any suggestions for how to do that? Oh yeah! When I used “Property” in the animation actuator, it worked, BUT it does not allow for blending at all, so it just “POPS” into the animation.

you could do it with python (dont know if the rest of your stuff is in python or bricks)

object.playAction(name, start_frame, end_frame, layer=0, priority=0, blendin=0, play_mode=KX_ACTION_MODE_PLAY, layer_weight=0.0, ipo_flags=0, speed=1.0, blend_mode=KX_ACTION_BLEND_BLEND)

and have the speed as something relative to the property “scale”

like… speed = 0.1*object[“scale”] or smt

you can also march a property at a rate, like own[‘Anim’] and set the play speed to zero giving you very fine control for synchronized actions

object.playAction(name, own[‘Anim’], own[‘Anim’], layer=0, priority=0, blendin=0, play_mode=KX_ACTION_MODE_PLAY, layer_weight=0.0, ipo_flags=0, speed=0.0, blend_mode=KX_ACTION_BLEND_BLEND)
own[‘Anim’]+=own.localScale.magnitude *magnitude

or something close*

I do this using own.localLinearVelocity all the time :smiley: