NPC Model

What an NPC looks like once the game has built it: how tall it stands and the colours its faces are drawn in. It is measured the same way TObjectModel measures world objects.

Example:

model := TNPCModel.Create(npcDef);
WriteLn(model.Height, ' ', model.Colors);

TNPCModel

The same record as TObjectModel, with Valid being False when one of the NPC’s models couldn’t be read.


NPCModel.Create

function TNPCModel.Create(constref def: TNPCDefinition): TNPCModel; static; overload;

Builds def with TObjectModel.Build: its models recoloured, retextured and scaled as the definition asks, and lit with the ambient and contrast the client lights NPCs with.

The client lights NPCs from a different direction than world objects, which only changes which faces catch the light, not the range of shades they are drawn in.