Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changes between Initial Version and Version 1 of ~archive/md2Tutorial


Ignore:
Timestamp:
May 31, 2006, 11:18:24 PM (19 years ago)
Author:
bknecht
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • ~archive/md2Tutorial

    v1 v1  
     1= How to create a md2-Model for Orxonox =
     2Well, to find out, how you manage to create those models was a pain in the ass, I hope that there is a better way in the near future.
     3
     4== Introduction ==
     5For a complete md2-model I need at least 3 programs. Unfortunately they're not all open source software: Maya (or Blender (opensource)) to create an object file (*.obj), Milkshape 3D (I'm using version 1.7.8 in this tutorial) to create the animations and export it into the md2-fileformat and Photoshop or anything else to generate good textures. Most of the time Misfit helps to edit animations on existing md2-models.
     6
     7The problem with the md2-models is, that they save the animation into vertex-movement. This is a problem, because Milkshape doesn't get that and so we are only capabale of editing bone-animations with this particulary program. So we have to save our animation into another fileformat: ms3d.
     8
     9Be also aware that md2-models only work with moved vertex. You cannot recombinate models during an animation.
     10
     11=== Problems with Milkshape ===
     12Before doing anything big, you would rather like to check if Milkshape crashes if you try to safe anything into the *.ms3d file format. If it crashes download [http://www.chumba.ch/chumbalum-soft/files/mesa641dlls.zip these two dll-files] and put them into the Milkshape directory, this should help you out.
     13
     14== I want to start from scratch ==
     15Okay, so you have something in mind which should be animated. Cool, first you will have to model your object or person in Maya or Blender and save it as an object file (*.obj). Do not care about texturing yet, we will have to do this later.
     16
     17== I do have a model now ==
     18Start Milkshape and import the object file. Now we want to add animation. With persons or things with joints we're going to need a skeleton. A skeleton is a set of points connected to each other with bones in a child/parent-relationship. We know this with ParentNodes in Orxonox. Be aware that every new joint you add, will be a child of the joint which is selected when you place the joint.[[br]]
     19When your skeleton matches your model you will have to assign the model's vertex to the bones. Make sure you have chosen the selection tool and that you're able to select vertexes (Be sure you deselect "Ignore Backface").[[br]]
     20Change now to the joint-tab (at the right side of the screen) where you can see a list of all the joints you've created. If you want you can change their names (arm, leg, hand...) so you dan't mix them up. Select a joint in this list and then select the vertex which should be part of this limb. Then press "Assign". To check if it worked, use the button called "Sel. Assigned" to see which vertex are part of which joint. Here there is also this child/parent relationship: A vertex which is part of a joint is automatically part of any parent or grandparent of his joint.[[br]]
     21'''Important:''' Every single vertex must be part of a bone, otherwise the md2-model won't be exported by Milkshape.[[br]]
     22
     23== I have the model and the skeleton ==
     24Animations with skeletons are a lot easier than pure vertex animation. Fortunately Milkshape will convert skeleton animation into vertex animation when we export it, so we don't need to worry about this. Press now the "Anim" Button at the lower edge of your screen. And put in the numbers of frames you want to use in your animation into the box at the right. Let's take something between 15 and 25. It depends how complicated the movement will be. The more complicate the more frames you gonna need.[[br]]
     25Be sure you have selected the first frame with the drawer on the lower edge. Now press Ctrl+K or choose "Animate->Set key frame". We will probably only need 5 or 10 key frames in our animation since Milkshape will smooth the animation in the frames between the key frames. To those guys using flash for 2D animations: Milkshape connects all your key frames with motion tweens! Now you go to frame 3 or 4 and start moving and rotating joints. When you think this animation step is finished, press Ctrl+K again and go further to the 6th or 7th frame and move your joints further.[[br]]
     26Congratulatons: You just finished your first key frame to key frame 3D-animation.
     27
     28== What's about the texture ==
     29Right, almost forgot: In Milkshape it is really easy to add a texture. You will have to select different parts of your model and put parts of the texture on it like in a skin transplant. I will add some tips here if I did texturing myself.
     30
     31== My animation is finished and the model's got its texture ==
     32Now we have to export this thing. You will first have to create a file called md2.qc ("Tools->Quake III Arena->Generate Control File") then you should be able to export your animation into the md2 file format ("File->Export->Quake 2 (MD2)").
     33'''Important:''' You cannot edit a md2-file with Milkshape. If you want to edit your animation ever again, save it in the Milkshape file format (*.ms3d).
     34
     35== I have a md2-model I want to edit ==
     36Well you're doomed, Milkshape does not allow this.[[br]]
     37Just kidding: You will need "Misfit" (opensource) to open, watch and edit the md2-model and all its animations. Here you won't be able to use a skeleton, but you can alter some vertex (frame by frame).