Skip to content

NPC Bugs

focustense edited this page Oct 3, 2021 · 1 revision

An index, glossary, and basic troubleshooting guide for the variety of problems affecting NPC appearances in the game. The outcomes and causes are always the same, whether or not you use EasyNPC.

Blackface

Also known as: darkface, grayface (in Oldrim).

The most infamous of all NPC bugs manifests as a dark skin tone on the face, while the rest of the NPC's body has the normal skin tone for their race. Usually, the NPC is also bald and missing any facial hair, scars, warpaint, etc.

Blackface

What causes blackface?

The root cause of blackface is a mismatch between the head parts in an NPC's winning record and the head parts in the same NPC's winning facegen file.

Record Head Parts FaceGen Head Parts

Facegen files do not record the form IDs of head parts, and more generally don't have a concept of "head parts" at all. What the game actually checks is whether the node names in the NIF file (i.e. Facegen) match the Editor IDs of the head parts in the NPC record. When they don't, the game tries to regenerate the facegen data, doesn't do a stellar job of it, and this is what you get.

Most often, this bug is the result of an actual mismatch: the facegen file and winning record do not come from the same mod. However, the comparison is complicated by a variety of factors:

  • Head part records operate on an inheritance system, while the facegen is "flattened". The image above shows the NPC's "direct" head parts, but notice that the record does not reference any head, or mouth, like the facegen file does. When a head part "type" is not included in the NPC record, it is taken from the default head parts for that NPC's race instead.
  • Templated NPCs with the Use Traits flag derive all head parts from their template parent (any head parts they include are literally ignored).
  • Some head parts have no model, such as MarksMaleHumanoid00NoScar. These should not appear in the facegen file, even when referenced by the record.
  • Many types of head parts, especially hair and marks/scars, include references to "extra parts", which must also be present in the facegen file.

This complexity means that any and all of the following edits can potentially cause blackface:

  • Inconsistency between plugin load order and "mod order" or "file priorities"
  • Editing an NPC record without providing a facegen file (even if the edit is normally safe)
  • Providing a facegen file without an NPC record, or without any plugin at all (even if the facegen is otherwise compatible)
  • Changing template settings on any NPC
  • Changing the default head parts for any race
  • Changing the extra parts referenced by a head part

All of these causes, except the first one, are potentially safe and typically have no problems when only a single mod touches that NPC. It is when multiple mods each make different types of these edits that blackface-triggering conflicts emerge.

Do not listen to any mod author who says that his mod is "safe" or "compatible" because it only makes one of the above kinds of edits. Almost every NPC mod is safe and compatible in isolation. The problems happen when multiple mods with different assumptions about compatibility collide. Two different mods, one which only edits facegen and another which only edits record data, may appear to have no conflicts at all, yet cause blackface when put together in the same load order.

Exactly why said conflicts cause this particular outcome is a matter of some debate. It is speculated to be a result of the game not loading the face tint data, although removing the face tint in an external tool such as NifSkope results in a very different skin tone that looks more like a sickly grayish white. It appears instead that the game uses the wrong face tint, perhaps due to sloppy programming, or perhaps due to an intentional "fail fast" design choice.

What is the fix for blackface?

The record data needs to be made equivalent to the facegen data, or vice versa. There are many ways to do this, and no single way is the correct way for all situations. Rather, the correct workaround depends on what caused the problem in the first place.

  • If the facegen file is simply missing from the source mod (rare, but does occasionally happen), then regenerating facegen data using the Creation Kit may fix the problem, although it may also yield a vanilla result or some totally unexpected result. This process is much safer if the author of the broken/conflicting mod provided a "Facegen Kit", which is a standalone mod/file that you temporarily load while running the Creation Kit that replaces the vanilla morphs.
  • If the conflict is caused by a facegen-only mod colliding with a record-editing mod, and you want the facegen-only mod to "win", then the best fix is to patch the NPC record so that its head parts are equivalent to what is already in the facegen. Add missing head parts (not including extra parts) directly to the NPC and remove incorrect ones.
  • Some issues may also be fixed by reverting an undesirable edit to head parts, races or NPCs, from a large mod that includes these edits but does not really require them.
  • Mods that make sweeping changes to races and/or head parts tend to be severely incompatible with traditional NPC overhauls. Any of the previously-described fixes can potentially help, but it will be an extremely long, tedious, and error-prone process. It is better to choose one or the author - i.e. stick to standalone overhauls or race/head-part overhauls, but not both.
  • Template-related errors can usually be fixed by taking the facegen file for the template parent, and replacing the conflicted NPC's facegen file with a copy of the template parent's file.

Shouldn't EasyNPC handle all of this?

It does. But EasyNPC's design is based on the assumption that, since it is merging all of your other overhauls, you therefore don't need those other overhauls afterward and are going to disable them. If you don't (or can't) do that, then it is possible for another mod to conflict with EasyNPC, just like it was possible for the original NPC mods to conflict with each other.

That's why deactivating the original mods is so important, and so frequently emphasized. The post-build checker can take away some or all of the pain by resolving loose-file conflicts, but some issues, especially those caused by race and/or head-part replacers, are simply too complicated to resolve automatically and may not be possible to resolve at all.

Whiteface

Also known as: Baldface

A minor variation on blackface. The skin tone is normal, but the NPC reverts to vanilla face geometry and is often bald, missing facial hair/scars, etc.

Blackface

What causes whiteface?

Anything that causes blackface, when present in conjunction with the Face Discoloration Fix plugin. As the author describes:

  • NPC appearance overhauls that use custom sculpts and custom textures are safe to use with this mod installed, but if you have a conflict in your load order that breaks those mods, this mod will not be able to restore the intended appearance. It will only fix the discoloration.
  • NPCs whose heads get regenerated will always be based on their face morph data from your loaded plugins. They will also be affected by appearance mods such as Expressive Facegen Morphs and High Poly Vanilla Hair, which would normally only affect the player unless explicitly regenerated in CK.

Regenerating facegen data for modded NPCs in the Creation Kit without access to a Facegen Kit may also cause the same outcome or a very similar outcome, for the same reason: its output is based on vanilla geometry (sculpts are lost) and/or whatever meshes and morphs happen to be in your load order at the time, which is almost never the same as what the mod author was using.

What is the fix for whiteface?

Disable the Face Discoloration Fix plugin (optional, but recommended to make conflicts more obvious), or delete any facegen data for the affected NPCs that you generated from the Creation Kit. Then, fix it as you would fix a blackface bug.