Calling animations via the API in Armory3d?

Can object and armature animations be called to play using the API behind Armory3D, if not are there plans for this functionality on future builds? This includes UV animations as well.

I have read the tutorial on animations, but it doesn’t specify any ways to play animations using scripts or the API during gameplay. Upon hovering my mouse over an animation clip I have added it gives what looks like a Python equivalent “Object.cliptraitlist_index”. Although that may not even call the animation during gameplay and may be specifically for the Armory3D properties interface itself.

As for UV animations many game engines, especially UDK, have streamlined the process of such animations in their shader system.
Not only that the Blender Game Engine does have a way to achieve UV animations at least using the GLSL Material nodes.

I’m new to the forums, and Armory3D has been the improvement to the Blender Game Engine that I have sought for years. I have big expectations and hopes for this!

Hello @hevfas, many thanks for your kind feedback!

It is possible to control animation using scripting, unfortunately not yet documented - will fix that and come up with a proper tutorial in the next build sprint. Animation system needs a serious gear up, currently it is quite bare bones and export is often unreliable.

I added an example on animated UVs, not sure if this is what you are after but at least the basics appear to be working :slight_smile:

Cycles material used in the example:

Just tested the uvanim.blend and that is exactly what I’m after, thanks! It looks like the Cycles node layout is very similar to the GLSL node layout too!

The Attribute node is the one thing that looks the most foreign to me though… After searching “time” in the API documentation it came up with several results. My guess is it might be referencing “iron.system.Time”? If not, let me know, I haven’t delved into programming as much as I need to so I’m very much a beginner in that area.

Thanks for the feedback and the example!


You are right about the Attribute node referencing time - it is getting time value from iron.system.Time class. I will have to start a manual page on this. Once the drivers are implemented this should be also doable in a ‘standard’ way.