QUESTION: how to add unit effects?

j_mie6

Deity
Joined
Dec 20, 2009
Messages
2,963
Location
Bristol (uni)/Swindon (home)
Hello, in the Misc folder of the XML there is a file called CIV4EffectInfos.xml. In this file there is these...

Spoiler :
<EffectInfo>
<Type>EFFECT_GREATPEOPLE_ACTIVE_WARLORD</Type>
<Description>Activation effect for the warlord general</Description>
<fScale>1.0</fScale>
<fUpdateRate>2.5</fUpdateRate>
<Path>Art/Effects/unit_greatpeople/fx_GreatPeople_Warlord_Activate.nif</Path>
<bIsProjectile>0</bIsProjectile>
</EffectInfo>
<EffectInfo>
<Type>EFFECT_GREATPEOPLE_BIRTH_WARLORD</Type>
<Description>Birth of the Warlord</Description>
<fScale>1.0</fScale>
<fUpdateRate>2.5</fUpdateRate>
<Path>Art/Effects/unit_greatpeople/fx_GreatPeople_Warlord_Birth.nif</Path>
<bIsProjectile>0</bIsProjectile>
</EffectInfo>
<EffectInfo>
<Type>EFFECT_GREATPEOPLE_HIGHLIGHT_WARLORD</Type>
<Description>Highlight effect for the Warlord</Description>
<fScale>1.0</fScale>
<fUpdateRate>1.0</fUpdateRate>
<Path>Art/Effects/unit_greatpeople/fx_GreatPeople_Warlord_Highlight.nif</Path>
<bIsProjectile>0</bIsProjectile>
</EffectInfo>


firstly what do they do... for example is the EFFECT_GREATPEOPLE_HIGHLIGHT_WARLORD the red glow he has behind him?

and secondly how would I go about adding these effects to units for example adding the all of the effects to a warrior (to make a great warrior)

Because I wanted to make ethnic Great Generals and I was thinking of doing a praetorian with these glows as the Greco_roman Great Generals (using the general animations just using the praet artwork)
 
right... If you could do these for me (im pretty rubbish at those sort of things) then I could just change the skin for them unless you need the complete unit art and defines in which case I can zip the ones I need and send them to you... Then that would be great!

so do you think you could? If so then just tell me what animations, nifs etc you need and I can get them here...
 
As far as I understand you just want to have the red glowing effect of the Great General attached to a Praetorian, right? That's rather easy to do and I'm pretty sure you can do it yourself if you have basic experience with NifSkope. This is what you must do:
In the Great General nif you'll find some nodes that are not within the Praetorian nif. These are the ATTACHABLES and the EFFECT entries. The first ones make the red glow happen, the second ones are there for the shiny effect you'll see when the General is activated.
Spoiler :



All you'll have to do is to copy these Branches and paste them into your Praetorian nif at the same places. As you can see one of the ATTACHABLES is a child of a Bip node (the skeleton of the unit). While the EFFECT things happen on the plot the unit is standing on, the ATTACHABLES need to know where to happen on the unit. If you want the same glow as the Generals have, just paste ATTACHABLE_HIGHLIGHT_WARLORD node at the same place in your Praetorian nif. But if you want to change it a bit, you could attach it to an other place of the skeleton. For example, you could paste it into the War_Sword Bip to give the unit a glowing sword.

I hope this helps. :)
 

Attachments

  • Warlord_Glow.jpg
    Warlord_Glow.jpg
    150.8 KB · Views: 354
1. Neither do I have nif scope or any experience with it...... thats the problem....

2. If those changes would happen would it only have the glow on it or the animations when you would activate the "Great Praetorian" so that when I used the new Praetorian when I was to join it with a unit it would use the animations? I don't mind what it does but I was thinking of using this as an ethnic unit so it really needs the warlords animations too, but if it can't use the warlords animations what would it do when it was attached to a unit?

3. And the reason I was asking for you to do it was because of no1 lol
 
I can't even find the Praetorian art file lol I looked in vanilla , warlords and bts' assets/art/units and none of them have it in where is it????
 
AHHHHHHH!!!!!!!!!!!! where is the Praetorian art file I have looked EVERYWHERE!!!!!!!!!!!!!!!


Please help...
 
AHHHHHHH!!!!!!!!!!!! where is the Praetorian art file I have looked EVERYWHERE!!!!!!!!!!!!!!!
It's in ...\assets\art\units\unique\roman\praetorian\..., part of the vanilla art files.

Also: Have you unpacked the art files for vanilla already? If not, let me explain: All vanilla Civ artwork (ditto for many mods) are in .fpk files. The vanilla files are in ...\assets\... and are named assets0.fpk, assets1.fpk etc. Use PakBuild to extract the artwork from the files.

Cheers, LT.
 
ok where do I extract it too and if I extract to my desktop what happens in the game do I extract them to the assets folder or what????

I don't really understand you say extract but where too the folders I expect to find them in???

Becuase I dont want to wreck the game by not knowing what i'm doing...
 
I can't even find the fpk?

It's not in assets and I saw that in documents/Games/bla bla there was an assets which contained them so I put it in to pakbuild and it said nothing about it...

EDIT: found the assets.0 etc now where do I extract to somebody elaborate??
 
cool
thanks I found the praetorian files and I am starting to work out nifSkope...

man this place sure is helpfull

now to tackle that pesky gamefont aswell:lol:
 
oh and how would I go about adding a cape to my great praetorian???
 
Good to hear that you took up the task learning NifSkope. :goodjob: It's a very powerful tool for unitmakers. There are a lot of helpful tutorials in Civ4 - Modding Tutorials & Reference subforum. For starters, this tutorial is very good:
http://forums.civfanatics.com/showthread.php?t=305606
Switching weapons is also quite easy with Nifskope:
http://forums.civfanatics.com/showthread.php?t=371739
For adding a cape to a unit, you'll have to find a separated cape mesh first. There are some unit accessories available in the download section:
http://forums.civfanatics.com/downloads.php?do=cat&id=102
I've separated a cloak of a unit for someone else some time ago, maybe you can use that one:
http://forums.civfanatics.com/showthread.php?t=157708&page=185 (post #3684)
If you find no fitting cape there, search for a unit that has one you like. I could separate it's cape for you via Blender. That's very easy most of the time.

Have fun unit modding. :D
 
thanks authough I can't work out what bits I need to be adding for the glow... because the preatorians are different if you could post a screeny of the warlord bits in their correct places within the roman praetorian stuff that would be great for me...

thanks, jamie
 
I found a guy with a cape I want! He is waiting for you to pull that pretty cape off him!

if you could send me the stuff I need using a zip that would be great and then as descibed above show me how to give it to my great praetorian would be even better!!! (as well as the glow thingy...)
 

Attachments

  • Guy to be Decloaked....zip
    64.6 KB · Views: 75
anyway aside from all of that in a recent test I did I used the standard warrior art for the great general and when I did it's commands it just stood there looking blank for a while and then disappeared with it's task complete... even when I have my caped praetorian with it's red glow, how do I get it to do the animations for the warlord when it does it's commands???
 
thanks authough I can't work out what bits I need to be adding for the glow... because the preatorians are different if you could post a screeny of the warlord bits in their correct places within the roman praetorian stuff that would be great for me...

thanks, jamie
I found a guy with a cape I want! He is waiting for you to pull that pretty cape off him!

if you could send me the stuff I need using a zip that would be great and then as descibed above show me how to give it to my great praetorian would be even better!!! (as well as the glow thingy...)

Naturally the Preatorian is different from the General because you haven't added the glow attachables yet. To add the glow, you'll have to put the two attachable nodes at the same place in the Preatorian nif as they are in the General nif.
If you look at their position, you'll see that the first attachable node (NiNode 56) is a subordinate (child) to the "MD NonAccum" node (NiNode 9) (parent). To transplant the glow to the Preatorian, you'll have to "Rightclick->Block->Copy Branch" NiNode 56 from the General nif, open your Preatorian nif, unfold the node structure until you reach the Preatorian's "MD NonAccum" node. "Rightclick->Block->Paste Branch" on this node and you should be done with the first attachable node. Do the same with the other node (NiNode 54), of course this time paste into the Preatorian's "BIP Pelvis" node, and you're done with the glowing effect. You might notice that the Generals parent node in this case is called "Bip01 Pelvis", not "BIP Pelvis". Don't worry about that, for unknown reasons the newer models skeletons are called Bip01, otherwise they are practically the same.
The cape of the unit is already separated, you can see that by leftclicking on the cape in the image of the unit. You'll see that only the cape will be overlaid with a white structure. To add it to your Preatorian, you should copy&paste the "cape" NiTriStripes node the same way you did with the attachable nodes. It's parent node is "BIP Spine1" in the old model, thus you should choose that node as parent for the cape node in the new model as well. After the addition, the cape might not fit to the model as you would like it to be. To correct its place, "Rightclick->Transform->Edit" on the cape in the image. Now should open a new window that can be used to change the position, angle and size of the cape.
 
anyway aside from all of that in a recent test I did I used the standard warrior art for the great general and when I did it's commands it just stood there looking blank for a while and then disappeared with it's task complete... even when I have my caped praetorian with it's red glow, how do I get it to do the animations for the warlord when it does it's commands???
Ah, the problem is, that the warrior has no "Activate" animation. The animation set a unit uses is defined in the CIV4ArtDefines_Unit.xml by the KFM entry. If you for example change this entry of the warrior to that of the Swordsman, you'll see that the warrior now behaves as if he is a Swordsman. One problem is, that older models have their skeleton named "BIP", while newer ones have it called "Bip01". So, to make the animation of a newer model (like the General) work for a older model (like the Preatorian), you'll have to rename the skeletion of the older model. This can be a real pain. To do so, unfold the "NiTransformController" node of the model and replace all "BIP"s with "Bip01"s. For example, the "BIP Pelvis" should become "Bip01 Pelvis". After that, the new animation set should work.
 
the NiTransformerController is this is it? (In purple) Do I also need to change the blue box too?

Spoiler :


the glow works perfectly now thanks just got to do this and the cape and then do for a couple of other units....
 

Attachments

  • Nifskope.jpg
    Nifskope.jpg
    152.9 KB · Views: 326
Top Bottom