What type of advice are you looking for; advice on how to model a lightsaber, how to get it in game, how to make it upgradeable, what type of lightsabers you should make, how to create a form of story behind each one, etc?
For modelling a lightsaber, you could read the 'A-Z of Modeling a new Lightsaber' thread by T7nowhere.
To get it in game, you could search around or try the following, which should work fine:
Section 1: Get your tools
I'm doing this for KotOR I, but KotOR II would be somewhat similar.
I would suggest the following three files:
Kotor Tool (
http://www.lucasforums.com/showthread.php?s=&threadid=121572)
KGFF (
http://www.lucasforums.com/showthread.php?s=&threadid=149407)
Hex Editor (A free one is located Here (
http://www.handshake.de/user/chmaas/delphi/freeware/xvi32/xvi32.htm#download))
Section 2: Get your files
I would advise you create a separate folder for all the files to get organized. So go ahead and create a new folder (name it whatever you wish).
Now get your icons in order. For now just get default ones, you can change them later. Open up kotor tool (make sure you’re in the kotor 1 section) and go to ERFs->TexturePacks->swpc_tex_gui.erf->I and go to iw_lghtsbr_001.tpc and iw_sbrcrstl_014.tpc and press ‘Extract file’ on each one (Save as TGA on each one), then save them to the folder you created.
Now get your item files in order. I’ll just get the default ones here as well, you can do the customizing once you get your item in game. Go to BIFs->templates.bif->Blueprint, Item and extract g_w_lghtsbr01.uti and g_w_sbrcrstl14.uti to the folder you created.
Now get your model and blade color in order. I’ll just use the default ones here as well, but you can use your custom model/texture as well. So let’s get the mdl and mdx files: Go to BIFs->items.bif->Aurora Model and extract w_lghtsbr_001.mdl to the folder you created, and go to BIFs->items.bif->Aurora Model Extension and extract w_lghtsbr_001.mdx to the folder you created. Now go to ERFs->TexturePacks->swpc_tex_tpa.erf->W and double click on w_lsabreblue01.tpc and check the box ‘Export Selection to TXI file’ and click on the Write File button and save the file to the folder you created. Take note of the text in the box (blending additive and decal 1) as these are the properties for the blade color, which makes it blend into the background.
You should now have all the files required, so let’s choose a model number. I don’t believe any mod uses 245, so change the files to that model number and change the blade color files to a name of your choosing. I’ll change the color files to mysaber_colo01. w_lsabreblue01 is 14 characters long, so the new name MUST be 14 characters long. This represents the current blade color, so if you were to be using the red saber (g_w_lghtsbr02.uti) that uses w_lsabrered01 then the new name would need to be 13 characters long. So let’s get started by changing the following files:
iw_lghtsbr_001.tga to iw_lghtsbr_245.tga
iw_sbrcrstl_014.tga to iw_sbrcrstl_245.tga
w_lghtsbr_001.mdl to w_lghtsbr_245.mdl
w_lghtsbr_001.mdx to w_lghtsbr_245.mdx
w_lsabreblue01.tga to mysaber_colo01.tga
w_lsabreblue01.txi to mysaber_colo01.txi
Next, let’s change the model to the new blade color. Open up your hex editor (I’m using the one I listed, so the steps won’t be the same on different ones) and open the w_lghtsbr_245.mdl file. Go to Search and then Replace. Under ‘Find’ and under ‘Replace with’, make sure to select Text string. Now let’s replace the old blade color with the new one, so type w_lsabreblue01 in the Find box and mysaber_colo01 in the Replace with box, and press Replace all (there should be 4 occurrences, though there with be 8 with a double saber). Now save the file.
Next, open the two item files in kotor tool. Open g_w_lghtsbr01.uti and change the Template ResRef and Tag to the filename you want to use for the item, I’m going to change them to newsaber. Change Model Variation to the model number you’re using, in this case we will put 245. Now go to the Description tab and change the Name field to whatever you want, I’ll just put New Saber. You can set the Description to whatever you want as well. You can also mess around in the Properties tab. Now save the file to whatever you chose as the Template ResRef and Tag, I’ll save it as newsaber.uti. Do the same for the g_w_sbrcrstl14.uti file.
Next, let’s make your saber upgradeable. Go into kotor tool and go to BIFs->2da.bif->2D Array and open up upcrystals.2da (if you already have an upcrystals.2da in your Override folder, then open that instead). You will see 6 columns: (Row Label), label, template, shortmdlvar, longmdlvar, and doublemdlvar. The (Row Label) column is just the next number. The label column can be whatever you want, so just name it something that signifies your new saber (I just put tutsaber). The template column is the name of the Template ResRef that you chose for the crystal (which should be the file name as well), I’ll put newcrystal since that is what I chose for my crystal. The shortmdlvar, longmdlvar, and doublemdlvar columns are the names of the Template ResRefs that you chose for the three item files, since we only created a regular long saber, put the name of the Template ResRef in your lightsaber's item file in the longmdlvar column and **** in the other two. So your columns should look like this:
(Row Label): 17 (this was the next number in my upcrystal.2da file)
label: tutsaber (again, you can put whatever you want)
template: newcrystal (the Template ResRef from my crystal’s item file)
shortmdlvar: **** (we didn’t make a short saber)
longmdlvar: newsaber (the Template ResRef from my lightsaber’s item file)
doublemdlvar: **** (we didn’t make a double saber)
Now you put all of your files in the Override folder. Everything should be working now.
A few added notes:
The name of the icon file for your lightsaber will always be iw_lghtsbr_xxx.tga (where xxx is the Model Variation you chose in your lightsaber’s item file). If you were to put 1 in as your Model Variation in your lightsaber’s item file, then the icon file would be iw_lghtsbr_001.tga, if you put 10 then the icon file would be iw_lghtsbr_010.tga, if you put 100 then the icon file would be iw_lghtsbr_100.tga, etc.
The name of your model files (the mdl and mdx files) will always be w_lghtsbr_xxx.mdl and w_lghtsbr_xxx.mdx (where xxx is the Model Variation of your lightsaber’s item file). The xxx has the same relativity as the icon file.
The name of the icon file for your crystal has the same relativity as the icon file for your lightsaber.
The Model Variation of your lightsaber and crystal do not need to be the same. Truthfully, aside from the entry in the upcrystals.2da, the lightsaber and crystal have nothing to do with each other.
You can edit the blade color file to your desire.