Modding Rundown: Animations

Started by thetommyboy2002, March 10, 2007, 11:21AM

Previous topic - Next topic
Yep, if I select just the animation I want in my notetrack (I use a tool I got with the Freedom force exportters called "character_tool", its a Max script which lets you select and display individual animations), ie "menu_idle" or "menu_goodbye" or even "attack_light1", then rename the "animation" in the "actor" part of the "alchemy dialog" in Max, I can export an individual animation which if named correctly (ie "17_swordsman.igb" for "menu_goodbye", or "17_swordsman_4_combat.igb" for "attack_light1") and placed in "actors", will play that animation at the time the relevant button/key is hit.
Still only one animation, but I now have Swordsman saluting as you start the game, and with a custom light attack animation in the game.
Which is very cool.
Next up, how the hell do I string them together?

Okay, that's beyond cool.  Kudos!  I'll have to see if that runs in MUAXbox

October 21, 2009, 06:01AM #32 Last Edit: October 21, 2009, 06:03AM by Mr. Law^^
Tommy you are the man! And another Great Comeback by one of the modders :D

I'll use the method and see if I can discover anything. 100+!

EDIT: Tommy, try using multiple actors and bind each animation to one. I had more than 2 actors before and could exported it (custom mesh though).

Quote from: Mr. Law^^ on October 21, 2009, 06:01AM
EDIT: Tommy, try using multiple actors and bind each animation to one. I had more than 2 actors before and could exported it (custom mesh though).

Every time I try to add another Actor and export, Max crashes. But the idea may have some merit. I'll try playing some more.

If it doesn't work, I guess adding notekeys at each new animation must be the way to go. So if animation 1 ends at frame 12, the new one starts at 13 and that's where the note has to be placed. Am I correct? (asking as a learner, I don't have any other exp in max but I'm eager to learn all of it XD )

Quote from: Mr. Law^^ on October 21, 2009, 09:05AM
If it doesn't work, I guess adding notekeys at each new animation must be the way to go. So if animation 1 ends at frame 12, the new one starts at 13 and that's where the note has to be placed. Am I correct? (asking as a learner, I don't have any other exp in max but I'm eager to learn all of it XD )

I have now gotten 2 igActors in the scene to export successfully, but it still plays only one of the animations, so I'm not quite grasping how to associate a set of keyframes with a particular igActor, and then a different set with another igActor and so on.
And yes, you understand correctly:

here you see two notetracks, the lower one I'm trying other naming conventions in the hope that the alchemy exporter accepts it (it doesnt), the upper one is in the format Freedom Force uses.
How you name each animation and where you put the notetrack can be critical to it working or not, so thats one ofthe variables I'm playing with. But it may be that MUA doesnt use notetracks at all, so it may be a waste of time.

Which animation does it play? The first one?

Perhaps renaming the igActors might help. For example naming it after the animation you want. The actors are the keys to the animations anyway. Perhaps the game can recognize the animations when the actors are renamed after them. So igActor01 as menu_idle, actor02 as menu_goodbye etc.

Hmmm...unless I'm missing something (which is always possible), you can only create one igActor from each part in a scene. Doing more was what was making me crash before.So my actors are created one from the main mesh, and one from the handle. Which may be why only one anim is playing (the second one, I think).
I did try renaming my two Actors to the animation names, but it still didn't work right.
I guess I could clone the main body for each new actor, I'll try that.
At the moment I've stripped out everything except menu_idle and menu_goodbye to simplify things.

Meh.
Heres what I have:
A mesh with biped, and two animations, menu_idle and menu_goodbye.
I clone the mesh itself and then make an igActor from each iteration of the mesh, one during each animation (in the vague hope that by association the actors will "know" to be paired with that animation. Talk about clutching at straws..)
I name each igActor after the animation it was created with/for.
But....on export I get a message about joint graphs, untill i link the handle node to one or other of the two actors.
If i link it to menu_idle, during the appropriate time, it plays through both anims.
But if I link it to menu_goodbye, neither seems to play.
So many variables, so little time...

Did you clone the mesh when it was skinned already? If so, I had problems with that before (sandman mod) so I had to clone the mesh, collapse to skin so it's the basic mesh again, and rerig it.

Quote from: Mr. Law^^ on October 21, 2009, 12:07PM
Did you clone the mesh when it was skinned already? If so, I had problems with that before (sandman mod) so I had to clone the mesh, collapse to skin so it's the basic mesh again, and rerig it.
because I'm not actually exporting geometry, the mesh(es) are physiqued not skin-ed. Thinking on it, its probably why the handle decides what plays, as bip01 is linked to the handle, and it's the biped not the mesh which is animated. So linking the handle/biped to one actor rather than another is why only one seems to work. But since you cant link the handle/biped to more than one actor (I think) that will make this difficult.
I'm just reading through all the max scripts installed with the artist pack in the hope of a better understanding.

Just FYI these anims crash XML2, so no dice there. :(

I'm sure the animations work in the same way exporting normal Biped animations work, except that it's exported in a particular way with Alchemy.  However, the same rules and creation techniques still apply.  This was something I was working on but haven't had time to do because of work.  So yeah, someone else was also working on animations, I just haven't been able to make quick progress because I get so little time to do anything these days.  However, I have a few gems of discovery to share once I get time to present them.
Some day, someone will best me.  But it won't be today, and it won't be you.


The artist formerly known as Burning Rage.

October 21, 2009, 02:05PM #43 Last Edit: October 21, 2009, 02:54PM by Mr. Law^^
I get the feeling the notes won't help at all. What you define in the actor is what is being exported.

Animations are bind to the actorskeleton. In this case, Bip01. We would be able to create a second skeleton for more-armed characters (yay for octavius) but that's just one new animation and that's it. We're totally overlooking something here.

EDIT: I think fiddling around with this in Maxscript might help:

Quote-----------------------------------------------------------------
   --  Constant local variables
   -----------------------------------------------------------------
   local ACTOR_ID = "igActor"
   local ACTOR_ANIMATION_NAME = "actorAnimation"

actorAnimation is the animation tommy was able to export. What if we add more? For example ACTOR_ANIMATION_NAME1 = "actorAnimation1"..

October 22, 2009, 05:33AM #44 Last Edit: October 22, 2009, 07:57AM by Mr. Law^^
Tommy, I think I might have found something. I think the export options are fine. When you export, you get a xxxDB.igb file which you found out. That said, here's my theory:

Since it's a database, we might be able to use it to combine it with new animations. There's an option in the exporter which says: "External Animations Path". It's there to use external databases located in the folder you specify. So if there are multiple DB's in there, those might be combined with the current one when exported, creating a new file.

E-Fockin-DIT: I think I figured it out! Almost, I think.

I exported one Database file called 161_greengoblin.igb which also exported menu_idleDB.igb as the database file.
Next up, I selected igActor01.igb, opened up it's properties and clicked on User Defined. Then I added this line after researching the DB file:

igAnimationDatabase = menu_idleDB.

Above the line are these lines:

igActor = true
actorAnimation = menu_idle <-- I changed this to menu_goodbye.

I unchecked the option under "Export Settings" called "Extract Anims" but I kept "Save Anims" checked. Then, I exported it.  I checked it out with a hexeditor and then in-game and voila. Both menu animsDB are in there.

EDIT: didn't really work. The animation was continuesly playing. Which makes me think about the animnums used in powerstyles. They are called ea_xxxxxx. Why? And does ea stand for External Animation? If so, are those the values that need to be put in the Notes?