Converting Civ V Units to Civ IV

Everything works thx a lot!

Sure the only animation working smoothly is the walking animation but I was expecting that, will need to redo the other animations as simply speaking...they're horrible plus will have to add sounds and animation, regardless as far as nif creation and addtion in game ( including the KFM file creation ) everything is working now ^^ , although I did try to load more than 4 units and the game simply freeze and I suppose that is due to the large textures I am using
Sounds good, I am happy that it works for you now.

One tip for the animations: Make sure you are timing them correctly. Best have a look at some of the vanilla ones and check how much time they give for each animation. For some, like idle and fidget, you have a lot of freedom, while others, like strike, hurt and die, need to be very exact. The reasons for this is that these animations need to fit to the animation of the other unit in combat. So, the point in time where the attack of the strike animation connects needs to be the same point when in the hurt animation the reaction starts (which is around the 0.3 seconds mark).

Have fun. :)
 
Honestly when it comes to animations I find that it's best to just start from a unit whose animations you mostly like and than just tweak them. Saves you a lot of pain in the long term.
 
Honestly when it comes to animations I find that it's best to just start from a unit whose animations you mostly like and than just tweak them. Saves you a lot of pain in the long term.
I am using a custom made skeleton so that's not really an option, I can just try to re-create the same animation but yeah..not easy, good enough for me to know that I can get the unit in game now...will take few days to fix the animations, CIV4 units have frame by frame, second by second animation which is...urgh
 
Sounds good, I am happy that it works for you now.

One tip for the animations: Make sure you are timing them correctly. Best have a look at some of the vanilla ones and check how much time they give for each animation. For some, like idle and fidget, you have a lot of freedom, while others, like strike, hurt and die, need to be very exact. The reasons for this is that these animations need to fit to the animation of the other unit in combat. So, the point in time where the attack of the strike animation connects needs to be the same point when in the hurt animation the reaction starts (which is around the 0.3 seconds mark).

Have fun. :)

Lol I don't have even a hurt animation, how many animations do actually must be inside the unit folder? : attack 1, attack 2 , idle , fortify-didle , fortify , death and walk...and now I need Hurt animation too
 
Lol I don't have even a hurt animation, how many animations do actually must be inside the unit folder? : attack 1, attack 2 , idle , fortify-didle , fortify , death and walk...and now I need Hurt animation too
Only need a hurt animation if you want the unit to have one. You could also skip on the fortify animation for now, think the game fills in that animation to a degree.

Also, you do not need to give each bone for each frame a position. The game will fill in the empty frames with in-between positioning, the same Blender and Nifskope does.
 
Only need a hurt animation if you want the unit to have one. You could also skip on the fortify animation for now, think the game fills in that animation to a degree.

Also, you do not need to give each bone for each frame a position. The game will fill in the empty frames with in-between positioning, the same Blender and Nifskope does.
Great! So I will keep the 7 animations limit
 
@Gearbolt38, for doing your animations, you may want to take a look at @Deliverator's tutorial, Converting Units from Kohan II, https://forums.civfanatics.com/threads/tutorial-converting-units-from-kohan-ii.356101 . Amongst the other info in it, it tells you how many frames you should use for the different actions, which was one of the hiccups I ran into with my unit (action taken and then unit vanished for a moment).
Yeah, the vanishing frame is what is happening with the attacking animations, I have only managed to make the walking animation fully work, will take a look at the thread thx
 
Yeah, the vanishing frame is what is happening with the attacking animations, I have only managed to make the walking animation fully work, will take a look at the thread thx
Make sure that all your bones have a set position for the first and the last frame of your animation. While Blender and Nifskope have no problems with bones having their animation start later or finishing early, for Civ4 this means the parts rigged to that bones will turn invisible.
 
I am using a custom made skeleton so that's not really an option, I can just try to re-create the same animation but yeah..not easy, good enough for me to know that I can get the unit in game now...will take few days to fix the animations, CIV4 units have frame by frame, second by second animation which is...urgh
Even than just importing the animation will set the 3d program to the appropriate time, add in the various sound effects etc. that the animation has. Than you can just delete all keyframes and start from scratch leaving the rest in. Especially if your custom skeleton has names that don't match the original.
 
Make sure that all your bones have a set position for the first and the last frame of your animation. While Blender and Nifskope have no problems with bones having their animation start later or finishing early, for Civ4 this means the parts rigged to that bones will turn invisible.

Ok almost got it!
But I am getting an invisible frame during the "Hurt" animation : like strike A and B I start from "Fortify" position at frame 0, around the 5th frame I start to move a little and at frame 10 I do a strong movement, then shift+d the original "Fortify" position and drag it down to frame 21. both strike animations are working with same timing ( at 10th frame the big attack comes then back to fortify at 21th frame ).

If I understand what you're saying then every single rigged part of the mesh must be lock locrot whenever I create an animation between frame 0 and fram X so let's say I move the right arm at frame 10 between 0 and 21, do I have to locrot entire mesh at frame 10?

If I undeerstood correctly then parts of the mesh turning invisible during an animation would make sense xd
 
Even than just importing the animation will set the 3d program to the appropriate time, add in the various sound effects etc. that the animation has. Than you can just delete all keyframes and start from scratch leaving the rest in. Especially if your custom skeleton has names that don't match the original.

I want to avoid all the "swapping" for now, I get confused still
 
Ok almost got it!
But I am getting an invisible frame during the "Hurt" animation : like strike A and B I start from "Fortify" position at frame 0, around the 5th frame I start to move a little and at frame 10 I do a strong movement, then shift+d the original "Fortify" position and drag it down to frame 21. both strike animations are working with same timing ( at 10th frame the big attack comes then back to fortify at 21th frame ).

If I understand what you're saying then every single rigged part of the mesh must be lock locrot whenever I create an animation between frame 0 and fram X so let's say I move the right arm at frame 10 between 0 and 21, do I have to locrot entire mesh at frame 10?

If I undeerstood correctly then parts of the mesh turning invisible during an animation would make sense xd
A bit hard to describe, but maybe these examples help:
Spoiler :


This should work alright. The empty frames for the Pelvis are not a problem, since the sofware will just fill in the empty frames with a gradual movement between the two frames with set positions. Also a single key frame at the start like for MD and MD NonAccum should be fine, but I would normally add also a key frame to the end, like it is the case for Grenadier_Sword and MatchStick.

Spoiler :


This will give problems. For the first three frames, the whole mesh will be invisible, since the Pelvis bone has no key frames till then and will therefore turn invisible, together will every bone that is child to it. Further, for the last three frames, the right hand will disappear, since the Hand.R has no following key frames at this point. Also the Grenadier_Sword will be invisible, since it is a child note of Hand.R. The rest of the model will still be visible.

Hope this helps. :)
 

Attachments

  • okay.jpg
    okay.jpg
    111.4 KB · Views: 327
  • notokay.jpg
    notokay.jpg
    98.4 KB · Views: 280
TLDR the first thing you should do when making a new animation is go to frame 0, select all your bones and add a new keyframe to fix a starting position.
 
A bit hard to describe, but maybe these examples help:
Spoiler :


This should work alright. The empty frames for the Pelvis are not a problem, since the sofware will just fill in the empty frames with a gradual movement between the two frames with set positions. Also a single key frame at the start like for MD and MD NonAccum should be fine, but I would normally add also a key frame to the end, like it is the case for Grenadier_Sword and MatchStick.

Spoiler :


This will give problems. For the first three frames, the whole mesh will be invisible, since the Pelvis bone has no key frames till then and will therefore turn invisible, together will every bone that is child to it. Further, for the last three frames, the right hand will disappear, since the Hand.R has no following key frames at this point. Also the Grenadier_Sword will be invisible, since it is a child note of Hand.R. The rest of the model will still be visible.

Hope this helps. :)

Does my skeleton need the MD bone? I can see a MD Non_accum node in nifscope for the model anyway, it seems to be auto generated by blender
 
Does my skeleton need the MD bone? I can see a MD Non_accum node in nifscope for the model anyway, it seems to be auto generated by blender
I never tried to not have the MD and MD Non_Accum nodes, so I cannot tell.
 
Managed in the end to create a working unit in game, by far not the best animations , you can hear the sound animation but for now I didn't manage to make the graphic effects work (like explosion or rifle gun fire), I did add the correct eventcode textfiles to each kf, the sound is working but the yeah the effect is not playing, despite all this everything working no invisible frame and the strike-hurt combination is exact :).

P.S If somebody could explain me why the special effects are not working while the sound is , it would save me time - Cheers :goodjob:
 

Attachments

  • FinalGundam.zip
    555 KB · Views: 52
Last edited:
I never tried to not have the MD and MD Non_Accum nodes, so I cannot tell.

I now understand the importance of MD and MD Non_Accum bones, CIV4 units use this bone as anchor to the ground and the rest of the skeleton while originating from MD won't be parented to it, basically you are able to rotate the lower part of the skeleton without it losing its footing on the ground plane....this is something I had to work around with my custom skeleton , my animations suck because I can't rotate the lower part without the animation appearing jumping location from frame 1 to frame 3 for example. MD add that necessary quality factor to the animation, without it any animation while working , will appear wonky in some instances.

My skeleton originates from the Core bone in the torso, a mistake to avoid for next time :crazyeye:
 
Managed in the end to create a working unit in game, by far not the best animations , you can hear the sound animation but for now I didn't manage to make the graphic effects work (like explosion or rifle gun fire), I did add the correct eventcode textfiles to each kf, the sound is working but the yeah the effect is not playing, despite all this everything working no invisible frame and the strike-hurt combination is exact :).

P.S If somebody could explain me why the special effects are not working while the sound is , it would save me time - Cheers :goodjob:
Effects need a node in the nif file from which they can be displayed. So, for example, "Effect:RIFLEBLAST_MODERN:EFFECT_RIFLEBLAST_MODERN" means that from the RIFLEBLAST_MODERN node the EFFECT_RIFLEBLAST_MODERN effect should be displayed. Getting the effects displaying into the right direction can be tricky, but normally they work fine if the effect node is a direct child of the MD NonAccum node.

I have modified your model by adding a RIFLEBLAST_MODERN_RIGHT and a RIFLEBLAST_MODERN_LEFT node. Also, I changed the Attack animations that from both notes at time an effect is triggered. Probably not directly as you intended, but you should be able to go from there. If you want to fine adjust the position of the effect nodes, it is helpful to activate "Draw Nodes" in the "Render" menu of NifSkope.
 

Attachments

  • Gundam_mod.zip
    490.8 KB · Views: 72
Top Bottom