1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

[Tut] Nifscope

Discussion in 'Civ4 - Modding Tutorials & Reference' started by The_Coyote, Jan 8, 2009.

  1. SaibotLieh

    SaibotLieh Emperor

    Joined:
    Sep 25, 2009
    Messages:
    1,524
    Here you go. :D I've also changed the nodes back to the spy model, because I had to modify the archer nodes quite a lot to make the unit look right. Haven't done this kind of backswitching before, but the unit animations look fine so far. It might be that you'll have to rename the nodes from Bip01 to BIP.
     

    Attached Files:

  2. esvath

    esvath Apprentice of Erebus

    Joined:
    Mar 27, 2008
    Messages:
    1,403
    Thanks!

    Would you explain how to crop a head from the model? I could attach head/weapon/any object into a model but haven't been able to crop them (and also haven't been able to crop a model into headless... :D)
     
  3. SaibotLieh

    SaibotLieh Emperor

    Joined:
    Sep 25, 2009
    Messages:
    1,524
    You are welcome. I've switched the head with Blender. Never have tried it with Nifscope, so I don't know how it is done with that program. I think I've read somewhere that you can switch the head by scaling the original head node to zero and add the new head with it's own node. But as I said, I've never tried it myself.
    Btw, I've changed the scale of the clavicle or upperarm nodes of some of my models to 0.9 to make the arms a bit shorter. This often looks a bit more feminine. I think this isn't kept when the model is put onto a new set of nodes.
     
  4. The_Coyote

    The_Coyote Emperor

    Joined:
    Mar 1, 2008
    Messages:
    1,367
    Location:
    Europe
    if you have a head without body und want to do the change without Blender, the steps are like SaibotLieh said:
    - reduce the scale (something like 0.001 or smaller) of the Bip Head Node and
    - make the new head a child of this bone (best it works with unrigged heads - if the head is rigged you can remove the rigging if you remove the NiSkinInstance completely). You can also do it with rigged heads, but then the head must be outside the skeleton
    - Afterwards adjust the scale and position of the new head.

    if you have no separated head, you can work with Alpha, but tbh much better would be to do the head cut in Blender. Also you can rig the head in Blender and export the result. A small tutorial how to rig is in the animation tutorial (page 4 to 5, for heads a 100% rigging is possible, for bodies you should use weight painting [or you can try the copy bone weight copy script: http://forums.civfanatics.com/showthread.php?t=320560 to have a base rigging and fine adjust the errors])
     
  5. ambrox62

    ambrox62 Emperor

    Joined:
    Mar 24, 2005
    Messages:
    1,294
    Does bone weight copy work for LHs also (in a convenient way, of course)? Did anyone ever try it for LHs?
     
  6. The_Coyote

    The_Coyote Emperor

    Joined:
    Mar 1, 2008
    Messages:
    1,367
    Location:
    Europe
    i tried it one time so far, while in the result you have a basic rigging, there is still need for a lot fine tuning - especially in the face area (in my try the biggest problem was the mouth area - but i it will depend on the shape)

    If the mesh is already rigged to another leaderhead animation i would think that making a nifswap and afterwards import the mesh in Blender can be faster. But i also fear that i´m not the best adress for such a question
     
  7. Ekmek

    Ekmek on steam: ekmek_e

    Joined:
    Aug 7, 2002
    Messages:
    6,058
    Location:
    San Diego, California
    what is bone weight copy? I've never done it. I have done a lot of skeleton-swapping. just copy a LH over to the one you want to use as a base skeleton. if the bone names dont match up then rename the ones you are copying over (not the base skeleton you want to use) to the same name to something close. it saves a lot of rigging time and then (after a blender import/export) you can get just about any leader use an other LHs animations.

    i guess this is still on topic :lol:
     
  8. The_Coyote

    The_Coyote Emperor

    Joined:
    Mar 1, 2008
    Messages:
    1,367
    Location:
    Europe
    with bone weigth copy can can copy the rigging of one mesh to another (even competelely unrigged ones).

    It´s also - or only :confused: - useful if you don´t have rigging information available to perform a nifswap. But because i have never rigged a leaderhead by hand i can´t compare the needed amount of time and therefore the real usefulness of the script. But i still think it could be suitable to create the basic rigging for newly created suits, body armors etc., because it also copy the rigging weigths (vertice is affected to 20% percent by the clavicle and to 80% by the upperarm)

    (but i checked the old thread again, my PC needed around 20 min to do this for a complete leaderhead)
     
  9. NovaSilisko

    NovaSilisko Chieftain

    Joined:
    Jan 18, 2010
    Messages:
    69
  10. The_Coyote

    The_Coyote Emperor

    Joined:
    Mar 1, 2008
    Messages:
    1,367
    Location:
    Europe
    looked at your file, not sure what caused the problems. but at least your nif had no vanilla structure

    things i changed (best i can remember):

    added NiMultiTargetTransformController (and added all armature nodes and the Propellers there - animated nodes must be child of this node)
    added Effect, Sound and Attachables placeholder node (the is not really necessary)
    made the rigged model parts a more direct child of the MD NonAccum tree (you had them as child of the model dummy nodes - the armature - therefore they were affect 2 times by the animation)
    made the non shader model to accept the gloss map (also made a quick resize and brightness change of your gloss texture)
    removed the 'TCiv4MechNonShader' from the recon NiTriShape (would be only needed if you want a damage texture)

    as is saw you also have a custom animation, therefore please try first the attached nif without kfm entry in the xml and afterwards (if it works - i had no change to test, nifviewer says yes, but this tool could also display your model) with animation

    please remember, your need a reconplane.nif in your folder with the kfm, because your kfm refers to one

    and nice model :)

    edit: ok the model do not work, so there must be still another problem

    edit2: found the problem why the model did not worked. In the nif the number of properties for the NiTriShape 'recon' is set to three, but there are only two properties, as open property slot causes chrashes, so not sure if one of the steps above were necessary, because this one causes ctd for sure (i didn´t exchanged the attachment)
     

    Attached Files:

  11. NovaSilisko

    NovaSilisko Chieftain

    Joined:
    Jan 18, 2010
    Messages:
    69
    Still is crashing...this is the XML code I have for the art def

    Code:
    		<UnitArtInfo>
    			<Type>ART_DEF_UNIT_RECON_PLANE</Type>
    			<Button>Modules/ReconPlane/icon.dds</Button>
    			<fScale>0.36</fScale>
    			<fInterfaceScale>0.7</fInterfaceScale>
    			<bActAsLand>0</bActAsLand>
    			<bActAsAir>0</bActAsAir>
    			<NIF>Modules/ReconPlane/reconplane.nif</NIF>
    			<KFM/>
    			<SHADERNIF>Modules/ReconPlane_test/test.nif</SHADERNIF>
    			<ShadowDef>
    				<ShadowNIF>Art/Units/01_UnitShadows/GunshipShadow.nif</ShadowNIF>
    				<ShadowAttachNode>BIP Pelvis</ShadowAttachNode>
    				<fShadowScale>0.75</fShadowScale>
    			</ShadowDef>
    			<fBattleDistance>0.5</fBattleDistance>
    			<fRangedDeathTime>0.12</fRangedDeathTime>
    			<bActAsRanged>0</bActAsRanged>
    			<TrainSound>AS2D_UNIT_BUILD_UNIT</TrainSound>
    			<AudioRunSounds>
    				<AudioRunTypeLoop>LOOPSTEP_GUNSHIP</AudioRunTypeLoop>
    				<AudioRunTypeEnd>ENDSTEP_GUNSHIP</AudioRunTypeEnd>
    			</AudioRunSounds>
    			<SelectionSound>AS3D_UN_GUNSHIP_FORT</SelectionSound>
    			<ActionSound>AS3D_UN_GUNSHIP_FORT</ActionSound>
    		</UnitArtInfo>
     
  12. The_Coyote

    The_Coyote Emperor

    Joined:
    Mar 1, 2008
    Messages:
    1,367
    Location:
    Europe
    look for edit2 in my post above
     
  13. NovaSilisko

    NovaSilisko Chieftain

    Joined:
    Jan 18, 2010
    Messages:
    69
    Why are the biggest problems always caused by the stupidest and most insignificant things like that?

    Edit: It works, and I thank ye. Will post a pic as soon as I do some final tweaks.

    Edit2: Whee

     
  14. The_Coyote

    The_Coyote Emperor

    Joined:
    Mar 1, 2008
    Messages:
    1,367
    Location:
    Europe
    gratulation :)

    the first steps are always a bit hard and your problem was also not a real common one
     
  15. Manifold

    Manifold ModderProtectionAdvocate

    Joined:
    Aug 27, 2007
    Messages:
    1,580
    simple question: which dds-skins of the default civ4bts units are compatible?
     
  16. The_Coyote

    The_Coyote Emperor

    Joined:
    Mar 1, 2008
    Messages:
    1,367
    Location:
    Europe
    simple answer: no idea

    a bit longer: i have never checked the UV of the different units, i only made new units so far.

    1.) But you can easily check the Uv in nfiskope, open the unit in nifskope, go to the NiTriShape (or NiTriStrips) - Right mouse button - texture - edit UV (at least older nifskope version don´t work if the base texture is teamcolor.bmp - therefore best use the _fx version of the models for this)

    Now you see the UV of this unit and you can compare it with others, if they are similar the textures could be compatible (or they are after small adjustments)

    2.) Or you simply exchange (rename) the texture and look for the result in nifskope
     
  17. Manifold

    Manifold ModderProtectionAdvocate

    Joined:
    Aug 27, 2007
    Messages:
    1,580
    Thanks, i will try
     
  18. esvath

    esvath Apprentice of Erebus

    Joined:
    Mar 27, 2008
    Messages:
    1,403
    Hello, need some insight from the master again :D

    I want to make a Valkyrie nif. So I copy SaibotLieh's female spy and transplant it into FfH Seraph model. Since both nif use Bip01, everything is ok. The preview in nifscope also good, I even test it with the Seraph's fidget animation.

    The problem is, when I use the unit in a game, the neck and arms became too long. Instead of making a Valkyrie, I hatched a demoness :(. So, what did I do wrong and how to correct it? I attached the preview from nifscope, the in-game preview and the nif.

    Thanks!

    Edit : forgot to attach :D
     

    Attached Files:

  19. SaibotLieh

    SaibotLieh Emperor

    Joined:
    Sep 25, 2009
    Messages:
    1,524
    Nice idea. :)
    The cause for the long arms and neck is again my re-rigging of the bones. I tried transplanting a normal spy model and get better results, but some rigging will have to be done to make the unit look right. Could be done, but I think that getting your model to work would be the best solution. Sadly I just have no idea why it works with nifscope, but not in Civ4. :dunno: Guess it is similar to the modifying of the position of the BIP/Bip01 nodes directly, which doesn't translate into Civ4. :twitch:
    Oh, btw, just in case you might not know: You can transplant model that have BIP nodes into units that have Bip01 nodes and visa versa if you just replace the 'BIP' of each node with 'Bip01' in nifscope. At least it always worked for me so far.
     
  20. Ekmek

    Ekmek on steam: ekmek_e

    Joined:
    Aug 7, 2002
    Messages:
    6,058
    Location:
    San Diego, California

Share This Page