Merging animations from example files with your modell
I would like to explain the technique I used to animate my tanks. In short I used Tank_Complete.max example file, replaced Sherman tank with my own model, adjusted envelopes and exported it. At the end I had my tank with all the default tank’s animations and effects (except for damage states). It might be a little complicated at the beginning if you’ve never done it before, but after some practice you can do all the steps in no longer than half an hour.
You must have: 3DStudio Max, Civ4 Plugins, Fireaxis example files and your own model.
Let’s go!
1. Open Tank_Complete.max
2. Clean it up:
- delete models: tank and Tread
- delete dummies: Dummy_Tank_GunLeft (if you don’t have MG mounted on turret)
- delete damage dummies (optional): I don’t do damage states so I delete these
- delete all materials (except for Tank Dummy Wireframe): you don’t really have to, because they won’t be exported but you might get duplicate material warning when you import your model
- it’s helpful at this point to hide in viewport everything except for Dummy_Tank_Body, Dummy_Tank_Turret, Dummy_Tank_Cannon
- if you plan on doing more tanks, save now so you won’t have to repeat previous steps
3. Merge your model. Important - it should already be finished. It must be one object, cannot be a group, modifier stack should be collapsed. See the manual “Getting your units in Civilization 4” for the optimal model set up.
4. Adjust scale, rotation and position. Try to match your model with the dummies (Dummy_Tank_Body, Turret, Cannon) as close as possible. Work only with your model and always use uniform scale (the one that scales all 3 axes simultaneously). Don’t worry if it’s not perfect. The important thing is to have your and dummy turret centered. If the tank still don't fit in there you can adjust dummies.
5. Select your model and apply Skin modifier.
6. Add fallowing bones: Dummy_Tank_Body, Dummy_Tank_Turret, Dummy_Tank_Cannon. Now, as you move time slider you can see that your tank is moving around, though it’s still messy.
7. Adjust envelopes (the most tricky part).
The idea is to indicate which vertices of the mesh will be affected by the appropriate dummy (bone).
For example the cannon:
Chose Envelope sub-object in Skin modifier and pick Dummy_Tank_Cannon.
Move the Cross Section points until all the vertices of the cannon are inside.
Select vertices in viewport and use options Exclude or Include Verts to include only the cannon’s vertices into envelope. Make sure that Vertices option in Parameters:Select is on.
I personally find it easier first to remove all the verts and then include desired ones.
Finish the remaining bones the same way.
At the end all the vertices must be controlled by some bone. For the mechanical objects like tanks one vert should not be controlled by two or more bones (red colored vert).
Run the animation to see if you didn’t miss any vertices.
8. Adjust effects. You need to unhide effect dummies if you’ve hidden them before. They are responsible for various effects like explosions or smoke. Very often I end up with EFFECT_WEAPON_PANZER_FIRE in the middle of the cannon. To fix this just move the dummies where they are suppose to be.
9. Select 3 main dummies and hide them.
10. Export your brand new animated unit with CivilizationIV Export plugin. Leave the settings as they are. It will create model .nif file and .kf, .kfm animation files. Once you pick a name for your .nif file don’t change it unless you want to have weird bugs in game. If you really need to, export it again with new filename.
Voila! You’re done. It’s time to test your unit in game.
If you like to experiment here are a few ideas:
- it’s fairly easy to manipulate the special and sound effects. Why not make your unit disappear in a big nuclear explosion. All effects are controlled in Track View - Dope Sheet and by dummies, but that’s for another tutorial. Anyway it’s not very difficult and more or less explained in “Getting your units in Civilization 4” manual.
- so far we have 2 more example files: Pretorian and Chokunu. Another way of making new units would be to use and modify these models, which is possible as long as you stay in envelope boundaries.
I really wish they released more .max files especially for Infantry. Can anybody start a petition for that?
P.S.
If you noticed any mistakes or know more efficient ways to do something, please let me know. Thanks.
This is my first tutorial so if something is not clear, ask me. I will try to anwser in 2nd post.
Sharick
I would like to explain the technique I used to animate my tanks. In short I used Tank_Complete.max example file, replaced Sherman tank with my own model, adjusted envelopes and exported it. At the end I had my tank with all the default tank’s animations and effects (except for damage states). It might be a little complicated at the beginning if you’ve never done it before, but after some practice you can do all the steps in no longer than half an hour.
You must have: 3DStudio Max, Civ4 Plugins, Fireaxis example files and your own model.
Let’s go!
1. Open Tank_Complete.max
2. Clean it up:
- delete models: tank and Tread
- delete dummies: Dummy_Tank_GunLeft (if you don’t have MG mounted on turret)
- delete damage dummies (optional): I don’t do damage states so I delete these
- delete all materials (except for Tank Dummy Wireframe): you don’t really have to, because they won’t be exported but you might get duplicate material warning when you import your model
- it’s helpful at this point to hide in viewport everything except for Dummy_Tank_Body, Dummy_Tank_Turret, Dummy_Tank_Cannon
- if you plan on doing more tanks, save now so you won’t have to repeat previous steps
3. Merge your model. Important - it should already be finished. It must be one object, cannot be a group, modifier stack should be collapsed. See the manual “Getting your units in Civilization 4” for the optimal model set up.
4. Adjust scale, rotation and position. Try to match your model with the dummies (Dummy_Tank_Body, Turret, Cannon) as close as possible. Work only with your model and always use uniform scale (the one that scales all 3 axes simultaneously). Don’t worry if it’s not perfect. The important thing is to have your and dummy turret centered. If the tank still don't fit in there you can adjust dummies.
5. Select your model and apply Skin modifier.
6. Add fallowing bones: Dummy_Tank_Body, Dummy_Tank_Turret, Dummy_Tank_Cannon. Now, as you move time slider you can see that your tank is moving around, though it’s still messy.
7. Adjust envelopes (the most tricky part).
The idea is to indicate which vertices of the mesh will be affected by the appropriate dummy (bone).
For example the cannon:
Chose Envelope sub-object in Skin modifier and pick Dummy_Tank_Cannon.
Move the Cross Section points until all the vertices of the cannon are inside.
Select vertices in viewport and use options Exclude or Include Verts to include only the cannon’s vertices into envelope. Make sure that Vertices option in Parameters:Select is on.
I personally find it easier first to remove all the verts and then include desired ones.
Finish the remaining bones the same way.
At the end all the vertices must be controlled by some bone. For the mechanical objects like tanks one vert should not be controlled by two or more bones (red colored vert).
Run the animation to see if you didn’t miss any vertices.
8. Adjust effects. You need to unhide effect dummies if you’ve hidden them before. They are responsible for various effects like explosions or smoke. Very often I end up with EFFECT_WEAPON_PANZER_FIRE in the middle of the cannon. To fix this just move the dummies where they are suppose to be.
9. Select 3 main dummies and hide them.
10. Export your brand new animated unit with CivilizationIV Export plugin. Leave the settings as they are. It will create model .nif file and .kf, .kfm animation files. Once you pick a name for your .nif file don’t change it unless you want to have weird bugs in game. If you really need to, export it again with new filename.
Voila! You’re done. It’s time to test your unit in game.
If you like to experiment here are a few ideas:
- it’s fairly easy to manipulate the special and sound effects. Why not make your unit disappear in a big nuclear explosion. All effects are controlled in Track View - Dope Sheet and by dummies, but that’s for another tutorial. Anyway it’s not very difficult and more or less explained in “Getting your units in Civilization 4” manual.
- so far we have 2 more example files: Pretorian and Chokunu. Another way of making new units would be to use and modify these models, which is possible as long as you stay in envelope boundaries.
I really wish they released more .max files especially for Infantry. Can anybody start a petition for that?
P.S.
If you noticed any mistakes or know more efficient ways to do something, please let me know. Thanks.
This is my first tutorial so if something is not clear, ask me. I will try to anwser in 2nd post.
Sharick