PDA

View Full Version : Editing Animation folder



Tanauser
01-08-2008, 13:51
Hello
I am trying to unpack MTTW2 animations Pack.dat skeleton.dat in order to open the .cas with 3dsMax (or to enable Milkshape to read the files); I can't find the software to do so :help: ; Could you indicate which tutorial I must follow .
thanks

KnightErrant
01-08-2008, 15:26
You don't want to go that route, those would come out in raw form.
Caliban released his animations directory a good while back. You can
find it here:

http://www.twcenter.net/forums/downloads.php?do=file&id=1686

You can merge animations with Milkshape .ms3d models using the
Python animation utilities located here:

http://www.twcenter.net/forums/downloads.php?do=file&id=1469

Tanauser
01-08-2008, 17:20
Thanks answering

I've done so and that's what I have at the end http://freelog.chez.tiscali.fr/emoticon/Confus/Confus_1.gif

https://img220.imageshack.us/img220/3435/animationeq0.th.jpg (https://img220.imageshack.us/my.php?image=animationeq0.jpg)

https://img166.imageshack.us/img166/531/animation2nt0.th.jpg (https://img166.imageshack.us/my.php?image=animation2nt0.jpg)

https://img220.imageshack.us/img220/1627/animation3ys4.th.jpg (https://img220.imageshack.us/my.php?image=animation3ys4.jpg)

error message : unpack requires a string argument of lengh 4

https://img166.imageshack.us/img166/2520/animation4um6.th.jpg (https://img166.imageshack.us/my.php?image=animation4um6.jpg)

KnightErrant
01-09-2008, 04:58
Hi Tanauser,

Definitely looks like it died reading your .ms3d file.
I'll PM you an e-mail for me. Could you send the
the .ms3d model you want to merge with an animation
and I'll see if I can reproduce the same error and look
into it?

Tanauser
01-09-2008, 14:28
I'm trying to edit the .cas the MTW2_HR_Arquebus ; MTW2_Fast_Musket ; MTW2_Musket_Primary but I can't edit the animation :help:

Tanauser
01-09-2008, 18:37
Thank you !!!
http://freelog.chez.tiscali.fr/emoticon/Content/Content_15.gif I did it ! thanks for youhttp://freelog.chez.tiscali.fr/emoticon/Content/Content_27.gif

https://img211.imageshack.us/img211/5616/animationoe6.th.jpg (https://img211.imageshack.us/my.php?image=animationoe6.jpg)

I didn't know the 2 files had to be in the same folder ........;

Can you lead me for the steps to change the animation and to put it back so that the modeldb. will understand it .
I can deal with a static Mesh , moving the vertex around ...but I understand I Will have to do it on every frame :idea2: ; but I need to save it under which .....animation name Ms3d .... and/or unit_models Ms3d ? ...Also someting is very confusing because their are many animation regarding obviously the same reloading :
MTW2_Arquebuse_attack_missile_reload.cas
or MttW2_Musket_attack_missile_reload.cas
and ...sames _extended.cas

This blue coats mod is going to be something ....I will make a Winchester reloading

http://images2.hiboox.com/vignettes/4807/v9j9hqds.jpg (http://www.hiboox.com/lang-fr/image.php?img=v9j9hqds.jpg)
http://images2.hiboox.com/vignettes/4807/w42hwsxz.jpg (http://www.hiboox.com/lang-fr/image.php?img=w42hwsxz.jpg)
http://images2.hiboox.com/vignettes/4807/ewkrkgxz.jpg (http://www.hiboox.com/lang-fr/image.php?img=ewkrkgxz.jpg)


https://img144.imageshack.us/img144/717/mustangmod4ks3.th.jpg (https://img144.imageshack.us/my.php?image=mustangmod4ks3.jpg)
https://img69.imageshack.us/img69/3489/custerlaststand3xz8.th.jpg (https://img69.imageshack.us/my.php?image=custerlaststand3xz8.jpg)

https://img223.imageshack.us/img223/7613/sabre4vy6.th.jpg (https://img223.imageshack.us/my.php?image=sabre4vy6.jpg)
https://img223.imageshack.us/img223/4646/sabre3pi0.th.jpg (https://img223.imageshack.us/my.php?image=sabre3pi0.jpg)
https://img223.imageshack.us/img223/8944/sabre2xo8.th.jpg (https://img223.imageshack.us/my.php?image=sabre2xo8.jpg)
https://img223.imageshack.us/img223/5725/sabre1nn5.th.jpg (https://img223.imageshack.us/my.php?image=sabre1nn5.jpg)

http://images2.hiboox.com/vignettes/4807/ogeu8uhl.jpg (http://www.hiboox.com/lang-fr/image.php?img=ogeu8uhl.jpg)
http://images2.hiboox.com/vignettes/4807/sishbn4x.jpg (http://www.hiboox.com/lang-fr/image.php?img=sishbn4x.jpg)
http://images2.hiboox.com/vignettes/4807/5g41rsg8.jpg (http://www.hiboox.com/lang-fr/image.php?img=5g41rsg8.jpg)

KnightErrant
01-09-2008, 21:19
Hi Tanauser,

(1) Let's just start with the basic stuff. You can change the animations
in the keyframer to something that better approximates the Winchester
action. You animate by rotating the bones or joints. You can experiment
on your animated file and just don't save the changes. Say you want to
change the first frame. You hit the key that looks like ||< (you get a tooltip
if you hover over it). Go to the joints tab and click on the joint bone_Relbow
to select it, then go to the model tab and press the rotate button. You
should see something like this:

https://img299.imageshack.us/img299/4751/animtutys3.th.jpg (https://img299.imageshack.us/my.php?image=animtutys3.jpg)

The way the human skeleton works you'll mostly rotate about the x-axis.
The units for those boxes are degrees. (Milkshape's coordinate system is
x-axis to the right of the screen, y-axis is upwards, and the z-axis is out
of the screen.) The rotations are relative to the current pose so you could
rotate by 10 degrees three times in a row to go 30 degrees total. Go back
and forth from the joints tab to the model tab selecting different bones and
experimenting, just don't save your model.

(2) At some point when you do have a completely redone animation you'll need
to extract it out from the Milkshape .ms3d file into a .cas file. Say your file
is called "bluecoat_animby_shoot.ms3d". Run the python animationutilities,
click the animextract button.

(If you get an error fussing about the line:
float_vec3.fromfile( fidcas, 7 ) at line number 1091, that's my fault.
Open animationutilities.py with any text editor and search for that
string. It only occurs once in the file. Comment it out by putting the
symbol # in front of it and saving.)

The animextract button will put up a file chooser, Mouse to your file
bluecoat_animby_shoot.ms3d and select it. It should produce a .cas
file named shoot_modified.cas, the _modified is so it doesn't overwrite
your original. Basically, whatever follows the _animby_ part will be the
name of the output file with _modified added to it.

(3) The animation family (defined in a moment) for a unit is specified in
the modeldb file. For instance, for armored_sergeants near the bottom
for that entry you would see:


5 slave
56 unit_models/AttachmentSets/Final Kite_slave_diff.texture
56 unit_models/AttachmentSets/Final Kite_slave_norm.texture 0
7 normans
58 unit_models/AttachmentSets/Final Kite_normans_diff.texture
58 unit_models/AttachmentSets/Final Kite_normans_norm.texture 0
1
4 None
10 MTW2_Spear 0
2
18 MTW2_Spear_primary
14 fs_test_shield 0
16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002


The red name is the name of the animation family.

(4) If you now go to descr_skeleton.txt, you can find the definition of the
family.



type MTW2_Spear
strike_distances 1.40 2.20 3.2 3.5 4.0
locomotion_table soldier

anim default data/animations/MTW2_Spear/MTW2_Spear_basepose.cas

;;;Defend
anim eager_defend_lo_stab data/animations/MTW2_Spear/MTW2_Spear_defend_stab_med.cas -fr -if:6 -evade -prob 10 -evt:data/animations/MTW2_Spear/MTW2_Spear_defend_stab_med.evt
anim eager_defend_mid_slashlr_light data/animations/MTW2_Spear/MTW2_Spear_defend_slashlr_med.cas -fr -if:7 -evade -prob 10 -evt:data/animations/MTW2_Spear/MTW2_Spear_defend_slashlr_med.evt
anim eager_defend_mid_slashrl_light data/animations/MTW2_Spear/MTW2_Spear_defend_slashrl_med.cas -fr -if:6 -evade -prob 10 -evt:data/animations/MTW2_Spear/MTW2_Spear_defend_slashrl_med.evt
anim eager_defend_overhead_stab data/animations/MTW2_Spear/MTW2_Spear_defend_stab_hi.cas -fr -if:6 -evade -prob 10 -evt:data/animations/MTW2_Spear/MTW2_Spear_defend_stab_hi.evt

;;;Reaction
anim knockback_from_front data/animations/MTW2_Spear/MTW2_Spear_knockback_from_front.cas -fr -evt:data/animations/MTW2_Spear/MTW2_Spear_knockback_from_front.evt
anim knockback_from_right data/animations/MTW2_Spear/MTW2_Spear_knockback_from_right.cas -fr -evt:data/animations/MTW2_Spear/MTW2_Spear_knockback_from_right.evt
anim knockback_from_back data/animations/MTW2_Spear/MTW2_Spear_knockback_from_back.cas -fr -evt:data/animations/MTW2_Spear/MTW2_Spear_knockback_from_back.evt
anim knockback_from_left data/animations/MTW2_Spear/MTW2_Spear_knockback_from_left.cas -fr -evt:data/animations/MTW2_Spear/MTW2_Spear_knockback_from_left.evt

(There's a lot more there, I just cut it off.) The first word after anim is
the action command which is followed by the path to the .cas file that
performs the action.

Basically, you would copy a MTW2_Musket directory to a new directory
named MTW2_Winchester. Then edit descr_skeleton.txt, copy the
MTW2_Musket family entry, name the new animation family
MTW2_Winchester, and change all the .cas path names for that entry
to point to the directory MTW2_Winchester. Then you can edit
whatever .cas files in that directory you want and they only apply to
units that specify MTW2_Winchester as their animation in the modeldb file.
In other words, you still have unchanged musket animations for all
other units.

There's some more steps but this is probably too long already.

Tanauser
01-10-2008, 00:11
Good evening
I can't see any joint or bones at all ; I can't have them appear
All I see is this https://img219.imageshack.us/img219/701/animation3hc9.th.jpg (https://img219.imageshack.us/my.php?image=animation3hc9.jpg)

I can rotate the forearm....but
I don't catch the process on how to give the new animation to the model

KnightErrant
01-10-2008, 01:14
It's always the details I forget. Go to the joints tab
and check the checkbox that says show skeleton. If they
come out as huge blue boxes go to File -> Preferences
and on the dialog that pops up, click the Misc tab. and then change
the joint size entry to 0.025. Then the joints should appear
normal.

Tanauser
01-10-2008, 07:41
I did so
https://img216.imageshack.us/img216/1719/animation4fj6.th.jpg (https://img216.imageshack.us/my.php?image=animation4fj6.jpg)

Tanauser
01-10-2008, 08:38
So I found that the model the nearest to the movement I need:
https://img216.imageshack.us/img216/159/animationru4.th.jpg (https://img216.imageshack.us/my.php?image=animationru4.jpg)

question appear
1) How do I save each rotation ?: I guess I would need 4 frames in front & 4 frames back with the right hand, that 8 changes
https://img216.imageshack.us/img216/2613/winchersterrechargementii9.th.jpg (https://img216.imageshack.us/my.php?image=winchersterrechargementii9.jpg)

This ms3d gives me 21 frames ; let say I want to start the movement at frame 15

https://img216.imageshack.us/img216/8923/animation2qt0.th.jpg (https://img216.imageshack.us/my.php?image=animation2qt0.jpg)

guessing : I start changing n°15 (rotation under -Y ), than I go to n° (-Y)16 , (-Y)17, (-Y)18 than backward 19( +Y) ...22 (+Y) So after the job done do I just save the file , and that's it ?


2) when I will be done I guess I'll have to create a special folder in which I will put this Change + all animation LESS the original reloading ?; save the folder under a special name and put it at the end of the unit in the modeldb. ??? ...later :dizzy2:

Tanauser
01-10-2008, 10:14
:inquisitive: :dizzy2:

The problem I meet is that the rifle is moving along with the hand

https://img227.imageshack.us/img227/6999/animation3zo0.th.jpg (https://img227.imageshack.us/my.php?image=animation3zo0.jpg)

https://img227.imageshack.us/img227/1559/animation4qe2.th.jpg (https://img227.imageshack.us/my.php?image=animation4qe2.jpg)

so when I rotate the hand I move the rifle also :oops: even if I reassign the weapon in order to make a new articulation in the wrist

So I have tried to create a New joint in the middle of the hand (joint tool >>>add a new joint between the selected one and it's parent)

https://img227.imageshack.us/img227/2033/animation5va5.th.jpg (https://img227.imageshack.us/my.php?image=animation5va5.jpg)


but I cant find a way to join it with the rest ....!?
For now I freeze investigating before you tell me more, maybe I am going the wrong way ....

KnightErrant
01-10-2008, 17:09
Hi Tanauser,

What you want to do, that is, animating the lever of the Winchester, is going
to be a lot of work for a detail many users may not even zoom in to see. An easier
thing is to just animate the right arm to drop down a little after each shot to
give the illusion of cocking to eject the spent round and chambering a new one.
Most players watching a company of bluecoats firing that way would understand that
they are seeing a rapid firing repeater rifle in action.

I'm not encouraging the easier way, just pointing it out as a fall back. If you
try the harder way and later decide it's too much work, you'll still have learned
a lot about using Milkshape and animations so it won't be a wasted effort.


Now, the mechanics of making joints. You are quite right, if you go to the model tab,
click joint and then click in a viewport, you get an isolated joint which isn't good
for anything. You need to add the new joint into the "bone hierarchy" of the model.
I'll explain that in a moment. Right now you just want to have a new bone coming off
of bone_Rhand, the terminology for that is that bone_Rhand is the "parent" and the new
bone is the "child". Go to the joint tab and select bone_Rhand by double-clicking it.
Then go to the model tab, click the joint button, then click in a viewport where you
want the new joint, somewhere near bone_Rhand. Once you click you should see blue lines
connecting bone_Rhand to your new joint. Since it was selected when you clicked, bone_Rhand
is now the parent of your new bone. You can go to the joint tab and double-click on
the new bone (probably called joint24 or something like that) and then in the edit
box below you can select the name joint24 and then type in a new name, like bone_lever
or something descriptive, and then click the rename button to the left to rename it.

A tutorial on the bone hierarchy:

Bones (or joints, a better and more descriptive terminology) form a tree structure with
one root node or joint. For human models with CA's standard skeleton, the root joint
is bone_pelvis. All other bones are children of bone_pelvis or of its children, down
several generations, so to speak. Americans and the English will know this children's song


"The hip bone's connected to the thigh bone,
The thigh bone's connected to the leg bone,
The leg bone's connected to the ankle bone,
The ankle bone's connected to the foot bone..."

It's actually kind of like that. Here's the hierarchy in CA's standard order:



1 [0] 2 [1] 3 [2] 4 [3]
bone_pelvis --> bone_RThigh --> bone_Rlowerleg --> bone_Rfoot

1 [0] 5 [1] 6 [5] 7 [6] 8 [7]
bone_pelvis --> bone_abs --> bone_torso --> bone_head --> bone_jaw
\
\ 9 [7]
-> bone_eyebrow


6 [5] 10 [6] 11 [10] 12 [11] 13 [12]
bone_torso --> bone_Rclavical --> bone_Rupperarm --> bone_Relbow --> bone_Rhand

6 [5] 14 [6] 15 [14] 16 [15] 17 [16]
bone_torso --> bone_Lclavical --> bone_Lupperarm --> bone_Lelbow --> bone_Lhand



1 [0] 18 [1] 19 [18] 20 [19]
bone_pelvis --> bone_RThigh --> bone_Rlowerleg --> bone_Rfoot





The first number above each entry is a 1-based index of that bone and the second number in brackets
is the index to its parent. The bracketed numbers are the hierarchy tree array for the skeleton.
They tell the game engine which bone is whose parent so it can multiply all the right rotation matrices
together to find out how to move a given vertex when an animation is played.

Actually I've simplified it a little to explain how it looks in Milkshape. In a .cas animation file
there is one more bone called Scene_Root that lies above bone_pelvis. It's position is always (0.0,0.0,0.0)
and it is never animated. The way the above is encoded in a .cas file is



Scene_Root 0
bone_pelvis 0
bone_RThigh 1
bone_Rlowerleg 2
bone_Rfoot 3
bone_abs 1
bone_torso 5
bone_head 6
bone_jaw 7
bone_eyebrow 7
bone_Rclavical 6
bone_Rupperarm 10
bone_Relbow 11
bone_Rhand 12
bone_Lclavical 6
bone_Lupperarm 14
bone_Lelbow 15
bone_Lhand 16
bone_LThigh 1
bone_Llowerleg 18
bone_Lfoot 19



In reality, the hierarchy tree array is a zero-based indexing into the bone name array with Scene_Root
included. Those integers in that order is what you find in every .cas file containing a human animation
for M2TW. This is a whole bunch of explanation to tell you that when you add bone_lever into your skeleton
we will need to add one entry to the hierarchy tree array right after the number 19. That number will be 13,
the zero-based index to bone_Rhand, which is it's parent. (This applies much later when the new skeleton
gets exported to a family of .cas files.)

KnightErrant
01-10-2008, 17:34
I realized the very next thing you are going to want to do after making
bone_lever is to assign vertices to it.

Bone Assignments:

Go to the joint tab and select bone_lever by double clicking it so the name appears
down in the edit box next to the rename button. Then go to the model tab and click
the select button. Down near the bottom of the model tab, in the group named "select options",
click the vertex button. Now use the mouse to select the vertices of the lever by dragging
a box around them. (You might have to do this procedure several times with small drag boxes to
avoid selecting vertices of the arm.) After selecting some vertices, go to the joint tab and
then click the assign button. You can go back and select more vertices while keeping the joint tab
open and repeatedly assign until you get them all. Once done, click away from the model in one
of the viewports to unselect everything. On the joint tab, check the checkbox named "Draw vertex weights".
Then double-click bone_lever and all the vertices assigned to it will show up red. This is how
you check your assignments. You can run through all the other bones to see how their assignments
show up as well.

Tanauser
01-10-2008, 17:35
Done
https://img235.imageshack.us/img235/2071/animationrb2.th.jpg (https://img235.imageshack.us/my.php?image=animationrb2.jpg)
and the articulation is working ; but let's do it the easyest way with the Right elbow like you started ...I follow you

Tanauser
01-10-2008, 17:57
https://img235.imageshack.us/img235/8528/animationqs5.th.jpg (https://img235.imageshack.us/my.php?image=animationqs5.jpg)

but the the hand is not moving or responding anymore so how do you associate vertices to joint (I mean make them standing together with the new joint_child)

KnightErrant
01-10-2008, 18:19
Are you in the keyframer? That is, did you click the anim button?
If you do rotations without being in the keyframer you are changing
the model, not making animations. Click the anim button, then go to
the joint tab and double-click a bone to select it, then to the model
tab, click rotate, then rotate about some axis by some amount of
degrees and see how it looks. There are edit boxes on the keyframer
where you can set how many frames you want (there are tooltips if
you hover over them). After doing a frame, go to the menu item animate
and select set keyframe to save that frame, then go to the keyframer and
step to the next frame and work on that. Try doing like a 5 frame
animation as a test, and then play it by clicking the > button.

Tanauser
01-10-2008, 22:00
I don't understand I think I'm lost ; whatever I rotate with the Right arm (hand , elbow , uperarm); the Gun comes with it...(its like if it was weld to the arm) I have tried to assign the gun again "Bone_weapon_weapon01 to musket ...it doesn't work

https://img225.imageshack.us/img225/3646/animationut4.th.jpg (https://img225.imageshack.us/my.php?image=animationut4.jpg)
.I have to go back from the begining
1) Open the merge Ms3d file (with the animation) selecting 5 frames /second
2) Click on the anim button ? so the model get in position
3 ) selecting the R_elbow from the joint Tab (dble click)
4) click on the Rotate or move button from the model Tab to give the motion I search?
5 ) Save the frame animation by clicking on the set keyframe from the menu Animate

KnightErrant
01-10-2008, 22:17
Hi Tanauser,

That's how animation works, the gun IS welded to the right hand when it's assigned to it.
Every child of a joint moves when you rotate the parent. If you rotate bone_Rupperarm,
every vertex assigned to it, AND every vertex assigned to bone_Relbow and bone_Rhand move as well.
Think of you own arm as an example: if you are rigidly holding an object in your right hand,
it has to move when you bend any joint in your arm.
The bone_weapon bones are children of bone_Rhand so they also move.

Tanauser
01-10-2008, 23:38
I understand ; so there is no way to have the weapon still ....; I will have to play with both arms to get the closest to the effect ...Rotate UP with Right elbow and follow the movement with Left Clavical .....that will keep me busy for few hours :laugh4:
I made already an animation with No weapon (as I have deleted it before) ; I had the idea of merge it after the job but it didn't work ....the animation was trembling and GOM didn't like it at all

I can send you the file when I am done to have your opinion ?

http://www.vangagifs.com/gifs/cartoons/luckyluke/15.gif

Tanauser
01-11-2008, 00:26
It was finally shorter than what I have expected

https://img219.imageshack.us/img219/6107/animationyd0.th.jpg (https://img219.imageshack.us/my.php?image=animationyd0.jpg)

a discreet movement from the wrist : I moved the Left elbow first than selected the rifle and rotate it counter-clockwise to make it appear still ... Now the file must go in a new folder containing all the animations of the musket LESS the reloading :inquisitive:

KnightErrant
01-11-2008, 03:59
Ah excellent! It's not really hard once you get the hang
of it. I'm working on something else right at the moment.
I'll try to give you the rest of the steps tomorrow on getting
your modified animation in game. Once you've got the whole
procedure working, it really is just using the keyframer on each
animation you want to mod and voila! a custom animation family
for your bluecoats.

Tanauser
01-11-2008, 15:02
I'm just going guessing
I have extracted the modified animation from the Ms3d file under

USspanish_dragoon_lod0_animby.cas

Put it in a new folder

America/data/animations/Winch_HR_Mod/USspanish_dragoon_lod0_animby.cas
along with all the others from the same family -minus- the one I am replacing

that is "HR_Arquebus_attack_missile_release.cas" (this is the .cas I have modified) -minus the original reloading file (the one I don't want to see in the game by the top of the gun) that is :

anim attack_missile_reload data/animations/HR_Arquebus/HR_Arquebus_attack_missile_reload.cas -evt:data/animations/HR_Arquebus/HR_Arquebus_attack_missile_reload.evt

............................


I have 2 US blueCoats units
Cavalry gives , in modeldb
.....1 5 Horse 16 MTW2_HR_Arquebus 13 MTW2_HR_Sword 2 19 MTW2_Musket_Primary


Infantry gives:
...1 4 None 16 MTW2_Fast_Musket 20 MTW2_Non_Shield_Fast 1 19 MTW2_Musket_Primary 1 18 MTW2_Sword_Primary
so MTW2_HR_Arquebus and MTW2_Musket_Primary are the animation family

lets take the first one
if I open descr_skeleton.txt it gives for MTW2_HR_Arquebus


;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;



type MTW2_HR_Arquebus
reference_points siege_engines/UnitModelsRefPoints/HR_Arquebus_Ref_Point.modelReferencePoints
parent MTW2_HR_Crossbow
no_deltas
in_awareness 135.0
in_zone 135.0
in_centre 45.0

;;; HR_Arquebus attacks


anim attack_missile_ready data/animations/HR_Arquebus/HR_Arquebus_attack_missile_ready.cas
anim attack_missile_hold data/animations/HR_Arquebus/HR_Arquebus_attack_missile_hold.cas
anim attack_missile_release data/animations/HR_Arquebus/HR_Arquebus_attack_missile_release.cas -evt:data/animations/HR_Arquebus/HR_Arquebus_attack_missile_release.evt

anim attack_missile_reload data/animations/HR_Arquebus/HR_Arquebus_attack_missile_reload.cas -evt:data/animations/HR_Arquebus/HR_Arquebus_attack_missile_reload.evt




;;; Weapon

type MTW2_HR_Arquebus_Primary
suppress_refpoints_warning
in_awareness 135.0
in_zone 135.0
in_centre 45.0

anim default data/animations/HR_Arquebus/weapon/w_HR_Arquebus_default.cas
anim stand_a_idle data/animations/HR_Arquebus/weapon/w_HR_Arquebus_default.cas

anim attack_missile_ready data/animations/HR_Arquebus/weapon/w_HR_Arquebus_default.cas
anim attack_missile_hold data/animations/HR_Arquebus/weapon/w_HR_Arquebus_default.cas
anim attack_missile_release data/animations/HR_Arquebus/weapon/w_HR_Arquebus_default.cas

anim attack_missile_reload data/animations/HR_Arquebus/weapon/w_HR_Arquebus_default.cas



;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;

Just guessing :dizzy2:
So now I should
replace

anim attack_missile_release data/animations/HR_Arquebus/HR_Arquebus_attack_missile_release.cas -evt:data/animations/HR_Arquebus/HR_Arquebus_attack_missile_release.evt

by my new animation USspanish_dragoon_lod0_animby.cas


but What about the .evt ? can I keep the same ?

Than I need to change that path in that descr_skeleton.txt
but if my file is in the America/Data folder is that OK ?
should I repack it or can I use the Animation from dl from TWC ?

:book:

Tanauser
01-11-2008, 17:51
Could you tell me if I need to repack ? ...and in which DATA folder (MTTW2 or AMERICA) :dizzy2:

Tanauser
01-11-2008, 19:10
I got CTD upon CTD , I don't know in which DATA/Animation/ folder I have to put the new one MTW2_Winchester ;
also what do I do with the pack.dat inside of each


This is how I have put it in the skeleton.txt

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;

[B]type ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;

type MTW2_Winchester
reference_points siege_engines/UnitModelsRefPoints/HR_Arquebus_Ref_Point.modelReferencePoints
parent MTW2_HR_Crossbow
no_deltas
in_awareness 135.0
in_zone 135.0
in_centre 45.0

;;; HR_Arquebus attacks


anim attack_missile_ready data/animations/MTW2_Winchester/HR_Arquebus_attack_missile_ready.cas
anim attack_missile_hold data/animations/MTW2_Winchester/HR_Arquebus_attack_missile_hold.cas
anim attack_missile_release data/animations/MTW2_Winchester/HR_Arquebus_attack_missile_release.cas -evt:/data/animations/MTW2_Winchester/HR_Arquebus_attack_missile_release.evt




;;; Weapon

type MTW2_HR_Arquebus_Primary
suppress_refpoints_warning
in_awareness 135.0
in_zone 135.0
in_centre 45.0

anim default data/animations/MTW2_Winchester/weapon/w_HR_Arquebus_default.cas
anim stand_a_idle data/animations/MTW2_Winchester/weapon/w_HR_Arquebus_default.cas

anim attack_missile_ready data/animations/MTW2_Winchester/weapon/w_HR_Arquebus_default.cas
anim attack_missile_hold data/animations/MTW2_Winchester/weapon/w_HR_Arquebus_default.cas
anim attack_missile_release data/animations/MTW2_Winchester/weapon/w_HR_Arquebus_default.cas



;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;


I have removed the anim reloading line (this one concerne the old reloading sequence animation maybe it's here the mistake )....in the new folder and in the text file

indicate 15 MTW2_Winchester in the modeldb instead of 16 MTW2_HR_Arquebus, I have put the New folder in each Animation folder beside the 2 pack.dat

What else ? http://freelog.chez.tiscali.fr/emoticon/Confus/Confus_10.gif

Time is on my side

KnightErrant
01-12-2008, 04:39
Hi Tanauser,

Sorry, was busy all day. I replied to your e-mail but didn't check this
thread. I was assuming you were running unpacked but I should have
checked. Do you have Caliban's unpacked animations directory as
your vanilla \data\animations directory, or are the only items in there
pack.dat, pack.idx, skeleton.dat, and skeleton.idx?

The way I run unpacked is:
I renamed my original \data\animations in the vanilla install to
\data\animations_orig so I have a safe copy of those four files.
I then put Caliban's directory as my vanilla \data\animations
directory.

Then I went to my mod folder, let's call it America to follow your notation.
If you have those four files in \America\data\animations you need
to save them somewhere else and remove them from that directory.
Note that we haven't yet put anything new in the game. Now start
your mod game and see if they get rebuilt. This process takes longer
than the normal load, like 60 or more seconds, so don't worry. If the game
loads everything is working as it should. All of this assumes you are
using io_filefirst and all that.
I can't remember if this makes a difference but my cfg file has this:


[util]
no_animdb = true

Caliban told us to do this but I think it didn't make a difference.

Now to test your animation in a simple way, simply back up the original
.cas file that you used for your modification. Then rename your
modded file to that name and put it in the right folder under the vanilla
\data\animations. (This assumes that the unit you are going to test
in-game uses this animation in its animation family.)

Now go to \America\data\animations and again move those four files
that got recreated out of that folder to a safe place. If you now start
your mod game it should rebuild using Caliban's unpacked .cas files only
now including your modified animation.

Later, when you want to create a whole new family of animations for your
bluecoats is when you get into copying and renaming folders in
\data\animations and editing descr_skeleton.txt and creating new family
entries there. It isn't that bad, it just takes a fair amount of editing and
there is always the possibility of making errors and getting CTDs that take
a long while to track down. This is why I'm outlining the simpler approach
above for testing a single animation in-game.

Tanauser
01-12-2008, 10:41
Hi
thanks for your advice and patience It's working more or less :sweatdrop:

https://img136.imageshack.us/img136/1319/erreuranimationgc1.th.jpg (https://img136.imageshack.us/my.php?image=erreuranimationgc1.jpg)

so the animation reloading IS CHANGED ! but I don't know why those guys are standing on there horse while doing the Clutch :laugh4:

So I have extracted the Whole Animation pack inside my /DATA/vanilla MTTW2 directory .......Rename My MTTW2_Winchester to HR_Arquebus (save HR_Arquebuse)

inside the HR_Arquebuse folder i Have the file I have moddified under the name of the reloading one that is: HR_Arquebus_attack_missile_reload.cas = This one is actually the HR_Arquebus_attack_missile_release.cas that I have taken for base to mod and rename after

I have to make tries , and tries to figure out what went wrong in the file
But it's a first result, I 'm happy http://freelog.chez.tiscali.fr/emoticon/Content/Content_23.gif

descr_skeleton not changed yet

Tanauser
01-12-2008, 13:12
I think the problem has something to do with the Extract animation of my m3sd file but I have no error report from the extraction:
Because If I rename the original RELEASE file into RELOAD it works well; these are 2 original files ; (I just replace the "reloading" file by "release" which from far looks OK ) If I use the one I have modded the soldier get up on his saddle when reloading

Tanauser
01-12-2008, 19:00
I know what it was ; OK ! I 'm on it .........almost done
(I had a 30/30 once)
http://www.gifmania.tw/weapons/hunting-gun/87gjhg.gif

KnightErrant
01-13-2008, 02:49
Excellent news!:2thumbsup: Never had a 30/30 but I
had a pellet gun made to look like a Winchester, long ago.:laugh4:
The good news is, all the other animation mods you make from now
on will be so much easier.

Cheers

Tanauser
01-13-2008, 12:06
:wall:
I still meet a problem ...I don't understand....

the HR_Arquebus folder is composed by a sub folder : Weapon
& 7 files :
HR_Arquebus_attack_missile_hold.cas ;;(evt) ;;_ready.cas (evt) ;;;release.cas (evt) ;;;reload.cas (evt) ;;; HR_Arquebus_stand_A_idle.cas



I have modded frame/frame the "Release.cas" (Set key frame each time in the Tab)(with the firing the movement I want at the end of the motion...the ms3d file run fine ....
https://img142.imageshack.us/img142/9530/animation0ch9.th.jpg (https://img142.imageshack.us/my.php?image=animation0ch9.jpg)

https://img142.imageshack.us/img142/4904/animationzj0.th.jpg (https://img142.imageshack.us/my.php?image=animationzj0.jpg)

https://img142.imageshack.us/img142/5755/animation2kz2.th.jpg (https://img142.imageshack.us/my.php?image=animation2kz2.jpg)
But it doesn't show in the game:dizzy2: ,when I replace it .... than I have changed the "Reload" one
by the same one (modded)...and the same mistake occurs , I don't see my modded frames , It's jumping across....
What mistake Have I done ? :sweatdrop:

Is there something else to do after extracting the .cas from the ms3d ?

Tanauser
01-13-2008, 14:54
Is that normal ? after saving the Ms3D file and reopening :

https://img213.imageshack.us/img213/7688/erreuranimationcm3.th.jpg (https://img213.imageshack.us/my.php?image=erreuranimationcm3.jpg)

seems that the joints have no weight

and in the game (loading with no problem (deleting each time the 2 .dat files in America/animations folder to recreate them) whatever I change in the animation ; it doesn't show up; ...it goes over it

all that job for :juggle2:

Tanauser
01-13-2008, 22:53
https://img91.imageshack.us/img91/1140/reloadingmv1.th.jpg (https://img91.imageshack.us/my.php?image=reloadingmv1.jpg)

The best I can do , but the rifle cannot stay still it moves along with the hand , which is not the real motion ....http://www.icone-gif.com/gif/corps/cerveau/cerveau-gif-013.gif

Tanauser
01-16-2008, 09:52
Ok I did the best I could without moving the rifle , because the model doesn't accept this in the game, so I had to play with the motion of both arms and shoulders to give the idea

this is a very short video sample : 7 mo you can see:
http://www.filecrunch.com/file/~cmkwdh

it's in avi ; just dl the little video on the disk and pay it with any player

let me know what you think

Tanauser
01-16-2008, 18:57
Breech reloading Animations for Download:

http://www.twcenter.net/forums/downloads.php?do=file&id=1808

KnightErrant
01-16-2008, 21:55
Been missing in action the last few days.
You got it working! You mentioned CTDs in the
other thread, just out of curiosity, was it a problem with the
modeldb entry or something in descr_skeleton.txt when you made
the new animation family entry? Just so others who want to make
animations will know what to watch out for.

Tanauser
01-17-2008, 12:21
Hi
I Cannot make another family entry in the descr_skeleton.txt (vanilla)according with the modeldb. (America)
- If I copy the whole entry from the HR_Arquebus and rename it ...MTW2_Bre_Reload (ex) gives the right path to it to the DATA/animations folder (vanilla) to a new sub dolder there in which I have passed my new files (example HR_Winchester and...
..... than modify the modeldb (America) US cavalry units with this new name MTW2_Bre_Reload refering to the descr_skeleton.txt (vanilla) entry : I got CTD WHEN LAUNCHING the BATTLE , not at start :book: :sweatdrop:

I have sent you a video of the unit new reloading ....I'm ready to re_do it ...but no one gives me an answer about it ...is it good or bad ?

KnightErrant
01-21-2008, 04:16
Hi Tanauser,

Finally got a chance to put your animation in game. This is the medium
difficulty option. For this I pretended that the musketeers were your
bluecoat model and I wanted to create a custom animation family for them
and have all others use the vanilla MTW2_Musketeer family.

My setup is this: I mod descr_skeleton.txt in the vanilla \data folder.
(Probably you could copy to your mod folder and io_filefirst would find it
there but my experiments from last summer were done this way so I'm
following that again.) I also mod the battle_models.modeldb file in the
vanilla \data\unit_models directory. This is non-negotiable I believe, the
game only parses this file in that directory unless something changed in
the 1.2 patch and nobody told me.

(1) Create a new directory in Caliban's animation directory. I called it
MTW2_Winchester. (Again, you might be able to do this in your mod
folder, I just didn't do it that way before.) I put your file
MTW2_Musket_attack_missile_reload.cas
with the changed reload animation in it.

(2) Edit the vanilla descr_skeleton.txt file (maybe a copy in a mod folder
would work, a good experiment to try). This is what I put in, I named
the animation family "MTW2_Winchester".


;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;


type MTW2_Winchester
reference_points siege_engines/UnitModelsRefPoints/Arquebus_Ref_Point.modelReferencePoints
parent MTW2_Musket
;locomotion_table soldier

anim default data/animations/MTW2_Musket/MTW2_Musket_basepose.cas

anim stand_a_idle data/animations/MTW2_Musket/MTW2_Musket_stand_A_idle.cas -fr -evt:data/animations/MTW2_Musket/MTW2_Musket_stand_A_idle.evt

anim attack_missile_reload data/animations/MTW2_Winchester/MTW2_Musket_attack_missile_reload.cas -fr -evt:data/animations/MTW2_Musket/MTW2_Arquebus_attack_missile_reload.evt

;;;;;;;; weapon


type MTW2_Winchester_Primary
suppress_refpoints_warning
parent MTW2_Musket_Primary

suppress_refpoints_warning

anim default data/animations/MTW2_Musket/weapon/w_MTW2_Musket_default.cas
anim stand_a_idle data/animations/MTW2_Musket/weapon/w_MTW2_Musket_default.cas
anim stand_a_to_ready data/animations/MTW2_Musket/weapon/w_MTW2_Musket_default.cas
anim stand_b_to_ready data/animations/MTW2_Musket/weapon/w_MTW2_Musket_default.cas
anim stand_c_to_ready data/animations/MTW2_Musket/weapon/w_MTW2_Musket_default.cas

anim ready data/animations/MTW2_Musket/weapon/w_MTW2_Musket_default.cas
anim ready_to_stand_a data/animations/MTW2_Musket/weapon/w_MTW2_Musket_default.cas

anim attack_missile_ready data/animations/MTW2_Musket/weapon/w_MTW2_Musket_default.cas
anim attack_missile_hold data/animations/MTW2_Musket/weapon/w_MTW2_Musket_default.cas
anim attack_missile_release data/animations/MTW2_Musket/weapon/w_MTW2_Musket_default.cas

anim attack_missile_reload data/animations/MTW2_Musket/weapon/w_MTW2_Musket_default.cas


Basically, all I did was copy the Arquebus entry, including the weapon bit,
and just renamed the red parts. Note that the parent keyword just
defaults everything back to MTW2_Musket. Since we don't have
a non-standard skeleton we DON'T have to copy everything to the
new directory. (If you had gone with the bone_lever option, that's the
really difficult way. All the animations have to be copied and the new
skeleton exported to, and the entry for this file gets really large.)

(3) Assign this new animation family to your unit in battle_models.modeldb.
For my experiment I just assigned it to the Musketeers.


10 musketeers
1 4
54 unit_models/_Units/RN_Light_Lmail/musketeers_lod0.mesh 121
54 unit_models/_Units/RN_Light_Lmail/musketeers_lod1.mesh 900
54 unit_models/_Units/RN_Light_Lmail/musketeers_lod2.mesh 2500
54 unit_models/_Units/RN_Light_Lmail/musketeers_lod3.mesh 6400
4
5 spain
71 unit_models/_Units/RN_Light_Lmail/textures/RN_Light_Lmail_spain.texture
72 unit_models/_Units/RN_Light_Lmail/textures/RN_Light_Lmail_normal.texture
40 unit_sprites/spain_Musketeers_sprite.spr
8 portugal
74 unit_models/_Units/RN_Light_Lmail/textures/RN_Light_Lmail_portugal.texture
72 unit_models/_Units/RN_Light_Lmail/textures/RN_Light_Lmail_normal.texture
43 unit_sprites/portugal_Musketeers_sprite.spr
5 milan
71 unit_models/_Units/RN_Light_Lmail/textures/RN_Light_Lmail_milan.texture
72 unit_models/_Units/RN_Light_Lmail/textures/RN_Light_Lmail_normal.texture
40 unit_sprites/milan_Musketeers_sprite.spr
6 venice
72 unit_models/_Units/RN_Light_Lmail/textures/RN_Light_Lmail_venice.texture
72 unit_models/_Units/RN_Light_Lmail/textures/RN_Light_Lmail_normal.texture
41 unit_sprites/venice_Musketeers_sprite.spr
4
5 spain
67 unit_models/AttachmentSets/Final European CB Gun_spain_diff.texture
67 unit_models/AttachmentSets/Final European CB Gun_spain_norm.texture 0
8 portugal
70 unit_models/AttachmentSets/Final European CB Gun_portugal_diff.texture
70 unit_models/AttachmentSets/Final European CB Gun_portugal_norm.texture 0
5 milan
67 unit_models/AttachmentSets/Final European CB Gun_milan_diff.texture
67 unit_models/AttachmentSets/Final European CB Gun_milan_norm.texture 0
6 venice
68 unit_models/AttachmentSets/Final European CB Gun_venice_diff.texture
68 unit_models/AttachmentSets/Final European CB Gun_venice_norm.texture 0
1
4 None
15 MTW2_Winchester
20 MTW2_Non_Shield_Fast 1
19 MTW2_Musket_Primary 1
18 MTW2_Sword_Primary
16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002



(4) Last step. Backup the pack.dat, pack.idx, skeleton.dat, and skeleton.idx
in your mod folder America\data\animations directory then delete them so
the game rebuilds the animation packs.

I played Spain (with Musketeers so using the new anim) against England
with Arquebusiers (not using the new anim).

https://img266.imageshack.us/img266/9256/tanauservf0.th.jpg (https://img266.imageshack.us/my.php?image=tanauservf0.jpg)

Please don't think this worked the first time for me. I fussed around
with it for two hours with endless CTDs before it worked. I think the
main thing is you can't skip the matching weapon section in descr_skeleton.txt
even though you don't use it.

Give it a try and post back how it goes.

Tanauser
01-23-2008, 09:51
[QUOTE=* I also mod the battle_models.modeldb file in the
vanilla \data\unit_models directory. This is non-negotiable I believe, the
game only parses this file in that directory unless something changed in
the 1.2 patch and nobody told me.=QUOTE]

So even if the unit modded is in the America extension , I have to mod the vanilla modeldb. ? :dizzy2:

You mean creating a new entry for US Cavalry in the MTTW2 vanilla ???

So if I follow well ; I have to mod both modeldb. ?

I 'll try it today and tell you if I had it worked
Thanks

Tanauser
01-24-2008, 01:01
It works only with the Cavalry so I have followed your advice with the Cavalry entry (MTW2_Winchester) instead of HR_Arquebus....
perhaps as you pointed out because of the same parent :
in HR_Arquebus we have weapon type HR_arquebus_Primary suppress_refpoints_warning parent MTW2_Musket_Primary suppress_refpoints_warning anim default

but in MTW2_Musket we have:

type MTW2_Musket
reference_points siege_engines/UnitModelsRefPoints/Musckett_Ref_Point.modelReferencePoints
parent MTW2_Knifeman

perhaps there is something to change there ; I couldn't tell

When I have tried to do the same to US_Infantry as I did to the US_Cavalry but this time with animation MTW2_Musket; It didn't go well , CTD on and on....I did exactly the same thing: in Vanilla DATA directory: Rename a new folder in Caliban unpacked Animations folder " MTW2_Winchinfant " in which I passed all the files from the original MTW2_Musket + mine (replacing (2) reload & extended reload)
Copy in descr_skeleton the entry MTW2_Musket and rename it under MTW2_Winchinfant
just changing the path to my 2 modded files

including the weapon bit which I call MTW2_Winchinfant_primary

than I have copied the unit entry from the America modeldb. into the vanilla modeldb (always rising by 1 the n&#176; of entry) and assigning after the .....5 Horse 16 MTW2_Winchinfant ....Well it didn't work ! I checked and checked it ..I didn't forget any slash bar ...I really really don't understand why it's working with one animation, and not with the other .

It's Weird that it went OK with HR_Arquebus replacement and not with MTW2_Musket ...too bad http://freelog.chez.tiscali.fr/emoticon/Confus/Confus_19.gif