Note: LucasForums Archive Project
The content here was reconstructed by scraping the Wayback Machine in an effort to restore some of what was lost when LF went down. The LucasForums Archive Project claims no ownership over the content or assets that were archived on archive.org.

This project is meant for research purposes only.

Custom appearance for NPC??

Page: 1 of 1
 Vox Kalam
09-15-2006, 7:26 PM
#1
I know there mst be a thread for this somewhere, but I haven't seen it...
I copied the head texture for one of the male PC heads, and photoshoped it, and now I want to give it to an NPC. Only thing is, I can't figure out how...
Helpy? Pleasey? :(
 Emperor Devon
09-15-2006, 7:28 PM
#2
Is this a new texture, or is it replacing an old one?
 Vox Kalam
09-15-2006, 8:02 PM
#3
New. I just used an old one as a template.
 Emperor Devon
09-16-2006, 2:27 PM
#4
If you yourself aren't using the head this was modeled off of, you could just replace the old head's texture with your new one. It would take a little less time than the other method.
 Vox Kalam
09-17-2006, 10:32 AM
#5
I don't want to replace one one of the PC heads...I'd rather make a new appearance, just for the npc. It's supposed to be a unique palpatine...
 stoffe
09-17-2006, 10:56 AM
#6
I don't want to replace one one of the PC heads...I'd rather make a new appearance, just for the npc. It's supposed to be a unique palpatine...

You'll have to modify two 2DA files to accomplish this. If you have some mod installed that already uses them you can find them in your override folder. Otherwise use KotorTool to extract them and save them in your override folder. Assuming this is a regular NPC and not a party member you could do like this:

heads.2da
Open with KotorTool and find the line in this file that represents the head you got the texture from originally. Copy this line (right-click on the gray border to the left and pick "Copy..." in the context menu), and paste it in at the bottom of the heads.2da file (by selecting the empty line at the bottom and typing something in one of the columns. Then right-click the gray border of the line and pick "Paste" in the context menu).

Then on this newly pasted line, change the value in the alttexture column to the name of your modified head texture file (without the file extension). Keep in mind that the filename can be at most 16 characters long and only contain alphanumerical characters and underscores.

If you've made darkside transitions as well, put the name of those files in the headtexvvve, headtexvve, headtexve and headtexe columns (for different grades of transition, though you can put the same texturename in all of them if you only have one texture).

Change the RowLabel to the next number in sequence Remember the line number of this new line, and the line number of the line you copied. Click on another line to commit the change and then save the modified 2DA file.

appearance.2da
Find one of the lines that reference the original heads.2da line you copied. Look in the normalhead column, the number here is a line number in the heads.2da file. If it was a player appearance there should be three of them. Pick a line (it doesn't matter which of the three you pick for this purpose) and copy it and paste it as a new line at the bottom of the appearance.2da file in the same manner as you did in heads.2da.

On this newly pasted line, change the value in the label column to something unique that will tell what the appearance is for. It doesn't matter what since the game doesn't use this line, it's only used to make the file more readable for humans (and help mod-installers differentiate between different lines, unofficially).

Then change the value in the normalhead column to the line number of the new row you just pasted and modified in heads.2da. Unless you have a new body model for the NPC, or want the head to be usable by the player or a party member, you shouldn't need to modify anything else.

Click on another line to commit the change and then save the modified 2DA files in your override folder.

UTC template
Open the UTC template for your NPC with KotorTool and find the Appearance input box and change it to the line you just added to appearance.2da. If you've set KotorTool (in the Options window) to read 2DA files from the override folder you should be able to find the label of your new line in the dropdown menu. (Or you can use a GFF Editor to open the UTC template, find the Appearance_Type field and just type in the line number of your new line in the appearance.2da file.)

Your NPC should now have your new head appearance in-game, as long as the NPC has not yet been spawned into the game in the savegame you use. This last part is important to keep in mind since if the NPC already exists in your savegame before you do this then their character data will point to their old appearance type, not your new one, regardless of your change in the UTC file. UTC files are used when the NPC is created, after that the data is kept in the savegame.
Page: 1 of 1