wc3campaigns
WC3C Homepage - www.wc3c.netUser Control Panel (Requires Log-In)Engage in discussions with other users and join contests in the WC3C forums!Read one of our many tutorials, ranging in difficulty from beginner to advanced!Show off your artistic talents in the WC3C Gallery!Download quality models, textures, spells (vJASS/JASS), systems, and scripts!Download maps that have passed through our rigorous approval process!

Go Back   Wc3C.net > Tutorials > MDL Editing
User Name
Password
Register Rules Get Hosted! Chat Pastebin FAQ and Rules Members List Calendar



Reply
 
Thread Tools Search this Thread
Old 12-07-2004, 02:43 PM   #1
Armel
User
 
Armel's Avatar
 
Join Date: Oct 2003
Posts: 661

Submissions (1)

Armel will become famous soon enough (27)

Default Animation Transfers in the MDL

Guess what? After all this time, I have found there is no real animation transfer tutorial here, and, though this technique is quite widespread now, many people still don't know how to do it. So please all the gods of mdl forgive me, I'm only making this for those who still don't know and want to learn.
But, some will say, there are tools to make it automatically. Yeah, but they have some issues and don't work for all models. And knowing how animation transfer works can be very useful for advanced mdl editing.

What you'll need:
- Yogbul's file converter to convert mdx models to mdl and then back to mdx
- War3viewer (optionnal, but makes model testing way faster; yet it doesn't always view models the same as wc3, world edit is the ultimate model testing program)
- notepad
- Oinkerwinkle's key redistributer program

In this tutorial, we'll add the footman's walk animation to the human peasant. First, convert both models to mdl using Yogbul's file converter, open the footman's mdl and go to "sequences" (it's the list of the model's animations, it's almost right at the mdl's beginning). Copy the walk animation part:

Code:
	Anim "Walk Defend" {
		Interval { 20000, 21100 },
		MoveSpeed 110,
		MinimumExtent { -37.5412, -31.6479, -3.83594 },
		MaximumExtent { 50.1027, 36.0322, 94.4434 },
		BoundsRadius 57.1482,
	}
...

and add it at the end of the peasant's animations list:
Code:
		MinimumExtent { -57.8447, -36.2669, -0.0542747 },
		MaximumExtent { 70.507, 34.1633, 117.941 },
		BoundsRadius 71.2252,
	}
	Anim "Stand Work Lumber" {
		Interval { 193133, 193733 },
		MinimumExtent { -57.8733, -43.083, -0.546668 },
		MaximumExtent { 70.5075, 35.2598, 118.031 },
		BoundsRadius 70.1906,
	}
	Anim "Walk Defend" {
		Interval { 20000, 21100 },
		MoveSpeed 110,
		MinimumExtent { -37.5412, -31.6479, -3.83594 },
		MaximumExtent { 50.1027, 36.0322, 94.4434 },
		BoundsRadius 57.1482,
	}

(Some vocabulary: I call "key" (but I think another word for this is "frame") a number that is used to say when an event will occur in a model. Animations can be considered as sub animations of a fictive unique animation, they are listed in the order they occur in this big animation and, in the sequences section where they are listed, the interval of each animation is made of two "keys" and corresponds to the instants when each animation begins and ends. We'll see further that such "keys" are also used in bone, geosetanims, particle emitters and eventobject parameters.)

Once this is done, modify the added animation's keys so that they are set after the peasant's former last animation (here we'll replace { 200000, 201100 } with { 20000, 21100 } for instance, ie we'll add 180000).

Now for the boring part: open Oinkerwinkle's Key Redistributer tool. Set the beginning and end keys of the input to 20000 and 21100 and the beginning and end keys of the output to 200000 and 201100. Go to the second bone (the first one is the corpse's bone, it is not animated) of the peasant and find the corresponding bone in the footman's mdl (the one that has almost the same name). You'll see a list of animation parameters called translations or rotations (bones usually have rotations, sometimes they have translations, and rarely they can have scalings; some bones have no animation parameters at all). Each of these parameters is placed after a number, which is the key at which this parameter will be used, so all the parameters of an animation use keys that belong to the interval of the animation that will use them.
Copy the translations between 20000 and 21100, paste them in the input and click "Redistribute". Then paste them after the last translation of the corresponding bone in the peasant's model. Do the same for rotations and scalings for each bone.
Make sure not to add a rotation to a translation list, it will cause a bug. Rotations must go with rotations and translations with translations.


NB:
- Some bones have no equivalent between two models, they are usually useless. However, you might have sometimes to reanimate them (eg: when transfering an animation from a unit without a cape to a unit with a cape) using the same method except that you'll take the animation parameters from another animation of the model (so if I add a walk defend anim from a capeless model to a model with a cape, I can reanimate the cape for this anim using the animation parameters of the walk anim of the model that has a cape).
- Many blizzard models use dummy bones associated with helpers (it's the case of the footman but not the peasant). So in fact when I speak of bones here it can be either bones or helpers. When you see that an important bone (root, head, foot, leg, pelvis, chest, arm, hand) has no animation parameters, look for its parent, it will probably be an animated helper. The best way to do anim transfer for models can be to look for all the important bones one by one and do the anim transfer for each of these, then look at the model and see if some bones don't need to be reanimated.
- Sometimes a model's bones have names that don't mean anything. In that case, you'll have to guess which bone is what using Oinkerwinkle's vertex modify program, but it's already a quite complicated tutorial so I won't explain this here.
- Depending on the way each bone uses its animation parameters (hermite, bezier or linear), there might be some graphical issues (luckily almost all bones use hermite). I don't know how to solve them, except that if you want to transfer from a bone using either hermite or bezier to one using linear parameters (no InTan or OutTan parameters) you can do the transfer then delete the InTan and OutTan for each of the transfered parameters of this bone, it should work.
- Before the Sequences list and, for each bone, before the translation, rotation or scaling sections, there is a number counting respectively the number of animations of the model and the number of translation, rotation or scaling parameters of the bone. Once you transfer anims these numbers will need to be fixed. Yet, not fixing them will not create a bug, at least not for War3viewer and WarcraftIII, so fixing them is useless. I don't know however if 3dsMax requires them to be fixed.
- When editing an mdl, be very careful to the syntax, it's really easy to make mistakes.
- You might want to fix the geosetanims, particle emitters and eventobjects to determine when they are visible (especially for total animation transfers, when all of a unit's anims are replaced by another one's anims), or they will appear at the wrong times (for instance you could hear the death sound while the unit is just walking peacefully). These sections usually have a list named "visibility" listing the keys to which they will be visible, 1 meaning visible and 0 invisible.
Use Key Redistributer to fix these visibility parameters.
- Animation transfer may look weird for models that have a very different scale of shape (like a Druid of the Claw and a priest).

I hope I didn't make it too detailed or confusing. Special thanks to Oinkerwinkle who helped me understand how animations work when I was trying to find out all alone.

Last edited by Armel : 12-12-2004 at 06:34 AM.
Armel is offline   Reply With Quote
Sponsored Links - Login to hide this ad!
Old 12-08-2004, 05:07 PM   #2
TheReaper
Mr.Reaper
 
TheReaper's Avatar
 
Join Date: Mar 2004
Posts: 1,105

TheReaper will become famous soon enough (54)TheReaper will become famous soon enough (54)

Default

That's a great tut there Armel
good job
__________________
"I am here, although I'm not,
You stand in fear, while i just nod.
You'll burst a tear, there's no doubt,
I'm here, i'm near, no need to shout."
- TheReaper


The Diary will never die...
The Ghoul's Diary Part 2!
Read all you want... if you dare...
TheReaper is offline   Reply With Quote
Old 05-26-2005, 08:40 PM   #3
A[noob]is
 
Posts: n/a
Default

It seems it's too detailed for me

Last edited by A[noob]is : 05-26-2005 at 08:41 PM. Reason: grammer
  Reply With Quote
Old 05-29-2005, 09:58 PM   #4
TheMinishCap
 
Posts: n/a
Default

its too detaled :'(
  Reply With Quote
Old 05-19-2008, 02:51 PM   #5
JarredGorea
User
 
Join Date: Feb 2008
Posts: 13

JarredGorea has little to show at this moment (0)

Question

nice tutorial - FOR ME TO POOP ON
JarredGorea is offline   Reply With Quote
Old 07-27-2008, 08:32 PM   #6
Shdow89
User
 
Join Date: Jun 2007
Posts: 2

Shdow89 has little to show at this moment (0)

Default Confused

This tutorial is 100 % confusing. You totally lost me after "copy the animation to the end list". Then you said put something in the Key Redistruibuter, you didn't say:
- Put what
- Put where in Range section, or in the clean sheets
- That thing to put, put both in Input or Output, or both
- What Bones, name of Bones, what name??
- What range, change what scalling to what value? What places, please point places with Code Tag
- What do you get in Key Red. when you that what you need to do
This is one of the worst both visual and text tutorial I ever saw. Text is just thrown all over with any reason. It is very confusing, tutorial maker didn't actually took in concern that he is dealing with newbies what it comes to this.
- What does NB stands for? Known Bugs?
I would really love if someone could do this again, cause it's a very fun skill, and if someone could just explain it a lot of better then this we would all be very happy. Thank you!
Shdow89 is offline   Reply With Quote
Old 10-29-2008, 11:50 AM   #7
unknown10x
User
 
Join Date: Mar 2008
Posts: 1

unknown10x has little to show at this moment (0)

Default

You said that "open the mdl and go to "sequences""... I tried but my computer says that the mdl is not a valid Win32 application... Please help! I'm just a newbie at this... I'm very sorry...
unknown10x is offline   Reply With Quote
Old 11-26-2008, 11:02 PM   #8
orospucocugu
User
 
Join Date: Jun 2007
Posts: 16

orospucocugu has little to show at this moment (2)

Thumbs down

Quote:
Originally Posted by Shdow89
This tutorial is 100 % confusing. You totally lost me after "copy the animation to the end list". Then you said put something in the Key Redistruibuter, you didn't say:
- Put what
- Put where in Range section, or in the clean sheets
- That thing to put, put both in Input or Output, or both
- What Bones, name of Bones, what name??
- What range, change what scalling to what value? What places, please point places with Code Tag
- What do you get in Key Red. when you that what you need to do
This is one of the worst both visual and text tutorial I ever saw. Text is just thrown all over with any reason. It is very confusing, tutorial maker didn't actually took in concern that he is dealing with newbies what it comes to this.
- What does NB stands for? Known Bugs?
I would really love if someone could do this again, cause it's a very fun skill, and if someone could just explain it a lot of better then this we would all be very happy. Thank you!

Totally agree.. The writer of this tutorial just threw this piece of crap of text-wall from out of his ass! You must be kidding me to put this shit on the tutorial section
orospucocugu is offline   Reply With Quote
Old 12-02-2008, 01:40 PM   #9
weg
User
 
Join Date: Oct 2006
Posts: 127

weg is on a distinguished road (11)

Default

you guys are simply impatient and ignorant
I've done this method quite a lot of times

(though I did the method with notepad and magos model editor; but the basics still apply)
weg is offline   Reply With Quote
Old 03-19-2009, 04:28 PM   #10
uR_tormented
User
 
Join Date: Nov 2008
Posts: 14

Submissions (1)

uR_tormented has little to show at this moment (0)

Default

Quote:
Originally Posted by unknown10x
You said that "open the mdl and go to "sequences""... I tried but my computer says that the mdl is not a valid Win32 application... Please help! I'm just a newbie at this... I'm very sorry...
You open the .mdl file with notepad or your usual text editor and do what it says.
uR_tormented is offline   Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off


All times are GMT. The time now is 05:55 AM.


Affiliates
The Hubb The JASS Vault Clan WEnW Campaign Creations Clan CBS GamesModding Flixreel Videos

Powered by vBulletin (Copyright ©2000 - 2019, Jelsoft Enterprises Ltd).
Hosted by www.OICcam.com
IT Support and Services provided by Executive IT Services