Get list of all actions?

Moho allows users to write new tools and plugins. Discuss scripting ideas and problems here.

Moderators: Víctor Paredes, Belgarath, slowtiger

Post Reply
ponysmasher
Posts: 370
Joined: Wed Aug 04, 2004 6:23 pm
Location: Los Angeles
Contact:

Get list of all actions?

Post by ponysmasher »

Is there a way in Lua to find out what actions exist?
I've managed to set actions, blend actions etc. But I just can't seem to find a way to get the names of all created actions.
User avatar
hothead
Posts: 213
Joined: Mon Apr 12, 2010 2:53 pm

Re: Get list of all actions?

Post by hothead »

ponysmasher wrote:Is there a way in Lua to find out what actions exist?
I've managed to set actions, blend actions etc. But I just can't seem to find a way to get the names of all created actions.
actions and blend morph i am now work am i plan to try and animate using only one layer with actions, blend actions so i'll love to know too and how they work

PERSON SHOULD GIVE THERE COMMENT ON OTHER PERSON POST BECAUSE IS THATS WHAT ENCOURAGE ME TO KEEP TRYING THAT IS WHY THIS FORUM IS SO DEAD AND BORING. you cant learn if you are not having fun.. :lol: :D :mrgreen: :lol: :mrgreen:
User avatar
Víctor Paredes
Site Admin
Posts: 5826
Joined: Tue Jan 25, 2005 3:18 pm
Location: Barcelona/Chile
Contact:

Post by Víctor Paredes »

uhm, Ponymasher, maybe you should ask to Rudiger, he is an expert scripter and have worked on very complex scripts using actions.
Image Image Image Image Image Image
Moho co-owner

Previously Rigged animation supervisor: My father's dragon, Wolfwalkers & Star Wars Visions "Screecher's Reach"
My personal Youtube Channel
Rudiger
Posts: 786
Joined: Sat Dec 17, 2005 5:25 pm

Post by Rudiger »

selgin wrote:uhm, Ponymasher, maybe you should ask to Rudiger, he is an expert scripter and have worked on very complex scripts using actions.
Sorry, but I don't know any way of getting the list of actions for a layer (at least according to the 6.1 API that Mike posted). I actually requested this feature from Mike a few weeks before AS7 came out, so I doubt it made it in, but you could check the automatically generated API from within AS, just in case. You can check whether an action exists or not, so there's always the exhaustive option of checking every Action name possible, if you've got a few spare millenia, but I wouldn't recommend it :?.

Perhaps you could use the old trick of parsing the source anme file for the info. For my morph dials scripts, I get my list of actions from the names of the bones, so I've never had to resort to doing this.
ponysmasher
Posts: 370
Joined: Wed Aug 04, 2004 6:23 pm
Location: Los Angeles
Contact:

Post by ponysmasher »

Yeah, I looked through the generated API and couldn't find anything.
For now I'll just hard code the names since I use the same names for all character (it's for lip sync so I need the mouth names).

Thanks for the help though!
Post Reply