Working With Nifs 301 : A Checklist

From the Oblivion ConstructionSet Wiki
Revision as of 07:58, 6 May 2007 by imported>Throttlekitty
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Mesh and Texture checklist

This is a quick checklist to help prep your .nif and .dds files for Oblivion. The exporters don't create a .nif that's totally usable by Oblivion. Always leave an extra nifskope window open for checking your nif against a working one to spot any problems. Compare line-by-line if you're having troubles! These tips are for working towards a final, usable file.

NIFS

In the Header (accessible when you first load a nif, or by doing View>Block List Options>List. Check: Version=20.0.0.5 Endian Type=1 User Version=11 You can optionally edit creator and export info 1 and 2 to leave your mark.


With all nifs, make sure that your hierarchy is clean, .everything is in order. Remove any unused properties. Some export processes create a bone list AND a bone hierarchy, you only need the flattened list, not the big long hierarchy. If you only have a bone hierarchy, you can rClick it, and opt to flatten it automagically.


Check that the NiNode's Flag is set to "Continue" (mode14)


Check Extra Datas appropriate for what you're making. If it's a helmet, you need a "Prn" string stating "Bip01 Head" If it's a weapon or similar, you'll also need a BSXFlag with the appropriate data there as well.


Check the normals on your mesh. I keep a test texture handy: It's flat gray with a white alpha channel. the normal map is "flat" just the flat blue, with an off-white alpha channel for high specularity. I attach this to my mesh, and set the following for material: Ambient=Black, Diffuse= Almost black, Specularity=White, Emissive=Black, and slide Glossiness to around 10. Then I Update the Tangent Space. I rotate all around my model, looking for any hotspots that don't look so good. If all is well, I return everything to normal (or just reload the file to save time).


Make sure you've updated tangent space on all shapes or strips. -Unless you're doing a special effect that doesn't require one. In that case, remove the BinaryExtraData block.


All shapes and strips have flag=Continue.


Check that all Properties and Datas are properly linked. If I have multiple shapes using the same alphaProperty, I make sure they're all referencing the same number, and delete any extra ones. Same goes for any other property.


Depending on your export process, you might need to set the "default" options for SourceTexture. Pixel layout should be "default, Mimaps can be Default or Yes, and alpha should be Default. Enter "1" for both unknowns.


CHECK YOUR TEXTURE PATHS! CHECK YOUR TEXTURE PATHS AGAIN!

Nobody wants to deal with "dissapearing meshes" or "Pink Textures" in their game.

If SourceTexture's "File name" field reads something like:

c:\program files\bethesda softworks\oblivion\data\textures\weapons\sword\sword.dds\ It is certain to cause problems for other users. Either go to the menu: Render>Settings, and set up your texture folders, or edit this field by hand to reflect the proper pathing. In this case, it would be:

textures\weapons\sword\sword.dds

Since Oblivion already declares c:\program files\bethesda softworks\oblivion\data\ As its base of operations for this instance.


If You've included Havok data, Make sure they're ordered properly.

Apply any Transforms, if you've changed position/rotation/scale: except on skinned meshes. (I think, it's been a while since I've had to move an armor piece in nifskope).


Check Node and Property names! If you accidentally renamed a bone, put it back. Some nodes, like the sheath or arrow nodes, need to be named properly to be used. Some special materials can be used by naming the MaterialProperty, doublecheck spelling.

-Remove duplicate properties. One mesh can't have two texturingProperty nodes attached. Make sure you haven't accidentally linked an improper node into Extra Data or Properties for a shape (or any other node, for that matter)


TEXTURES

There are a few other good texturing guides, so I'll just touch the basics for what's needed.

Your color map should be one of the DXT formats (you can use others, but these are your best bet), and have an alpha channel. If you're not using any effects, make it white.

texture_n.dds: The normal map works best at a DXT5, and also needs an alpha channel. The alpha channel here controls Specularity of the material. Black=dull White=shiny. Again, this isn't a texturing guide, but how you paint this area affects which portions are more or less shiny.

If you're using a glow map, a "..._g.dds" The Material setting in the .nif needs to have emissive turned to something other than a dark color. Anything colored black in the glow map will not allow the bright light to pass through. Lighter values will allow the texture to "glow in the dark" so to speak. It should also have a white alpha channel.

The engine will seek out the normal and glow maps based on their name, and the name of the base texture. It looks for the first underscore, and goes from there. If your texture is named sword.dds, it will expect sword_n.dds and sword_g.dds

If you have multiple retextures of the same mesh that use the same normal map, you can use one Underscore in your texture name:

sword_evil.dds sword_good.dds sword_n.dds sword_g.dds

Using both the good or evil textures, they will both use the same normal and glow maps. You cannot use multiple underscores.

Be sure to generate mipmaps. But not for icons. Again, seek out the other texture guides, as they already cover this, and troubleshooting steps for rendering problems.

Make sure that The textures are in the correct folders in the oblivion directory. (same goes for your mesh, eh?)


So, I think that's about it. I can't think of much else to add to this guide, so enjoy!