Editing Existing 1p Animations

Editing Existing 1p Animations

by mschoeldgen[Xww2]

Changing existing 1P animations ( and not creating new ones )

I was asked to publish this tutorial which was originally meant only for our mod team. It doesn't attempt to replace the great tutorials from junk, but as he removed them i decided to at least give animators in spe some hints on exporting and setup. Originally i used this method to only edit the most annoying wrong animations when using a vanilla animation system with our weapons, like reload and fire. Now that we have a dedicated animator its no longer needed but surely a few ppl can benefit from this method.

In this tutorial i'd like to explain the way how i recreate animations based on existing ones. For this purpose you should have set up the weapon with an existing but standalone animation system, that is you should have an own animations folder for that weapon. You can create this by cloning an existing /animations folder and the 2 'animationsystemNN.inc' files. Open the '\*.inc' files and change the paths inside them to point to your new animation folder. J

Your weapon's tweak file should also use that animationsystem.

You should have the bf2 plugins for 3ds Max as we need to import the 1P skeleton from /objects/soldiers/common/animations/1p\_setup.ske.

O.k, now that everything is prepared, open Max and setup the units to use Generic Units.If you fail to do so, strange things will happen :o First thing is the import of the 1P skeleton. Run the BF2 Plugins, select 'Import Skeleton' and browse to the above mentioned file. You will get that model in Max:

Image File: animA.jpg

Make yourself familiar with this display, its a representation of the two arms of the soldier. Now open the 'Select by Name' window and select the objects named 'mesh1' to 'mesh5' to delete them:

Image File: animC.jpg

In this case i deleted mesh1 to mesh5 cause my imported weapon ( the K98 ) has 5 meshes in it. Now we need to merge our weapon into the scene. Open the 'Merge' dialog (File menu) and browse to your weapon scene. We want to merge only the meshes of the geom0->lod0 weapon, our 1P model:

Image File: animB.jpg

Ok, we have the weapon in the scene , but its located at 0/0/0 :unsure:

Image File: animD.jpg

Lets do a preliminary positioning by selecting the parent of our weapon, in this case its the 'K98\_\_GenericFireArm' and moving it to 0.79 / 3.5 /13.81 . Rename this mesh ( the K98\_\_GenericFireArm ) to 'mesh1' and parent it to the 'root' helper . Now select the remaining meshes of the weapon (mesh2 up to mesh5) and also parent them to the root helper. In case the meshes where named differently rename them now to 'mesh2' and up:

Image File: animE.jpg

This is how it should look like before we import the animation to be changed. And there's no reason why we shouldn't do that now :D Once again open the 'Necessary Tools' and select 'Import 1P Animation'. Browse to your .baf file , noting its name:

Image File: animF.jpg

The weapon jumps into position and we can already slide the frameslider through our imported animation, seeing all the meshes move. But before we do any animation we should make our scene export-ready. Select the 'root\_skeleton\_1P\_setup' Pointhelper and rename it to 'root\_animation\_<MyAnimationName>. We are working on the '1p\_k98\_reload' animation and so our name would be 'root\_animation\_1p\_k98\_reload':

Image File: animG.jpg

All parts of the scene need to be in a 'Named Selection Set' named 'ANIMATED'. To do that, select all your meshes and bones and open the 'Edit Named Selection Sets...' from the 'Edit' menu in Max. Press the button with the curled brackets and name your new set 'ANIMATED' :

Image File: animK.jpg

Now everything's setup to start working.You should probably save that scene in its current state as you can use this as a starting scene for all your new animations. There are a few rules to obey, though. You shouldn't 'move' bones, only rotate them and you cannot use constraints, they will completely screw up your scene. You are allowed to move weapon meshes, though. Its best to switch your Reference Coordinate System to 'Local' to affect meshes and bones in a natural way:

Image File: animH.jpg

Animating is now done by pressing the 'Auto Key' button. Note how the time line turns red. Now each change to a position or rotation will only affect the selected frame. The task now is to select the mesh or bone you want to affect and do your rotation/move stuff. In case you rotate an arm bone, the lower bones will follow it. Work your way through each frame now. In case you want to copy the rotation/position of one or more meshes and bones to the next frame (or several frames), have your objects selected and hold down the <Shift> key while dragging the frame marker:

Image File: animI.jpg

Also note that you shouldn't do anything to the Camera bone as this determines the viewing position in the game.

Hints: Try it with a simple and short animation first, like a fire or a stand animation. When exporting your animation, make sure of the right path in the exporter window:

Image File: animJ.jpg

It is vital for any animation to have a clean weapon export before attempting to animate it. That is especially true for the scale and orientation of the weapon.