I recently tried to create a new shield type for use in Kotor 1. I edited the forceshields.2da and the spells.2da and was able to select the new line (from spells.2da) as an activateitem selection in the.uti, and was even able to use it in game.
However the shield I was using was colored red, when i had set the visualeffectdef column in forceshields.2da to green. (I copied the entry from the sith shield). I have been able to identify which damageflags used by the shields offer which defenses and changed it to the mandalorian power shield type, and have increased the amount (as in the amount of damage the shield can take) to 200. And yet none of these changes have taken place. I seem to use the basic energy shield.
I am obviously missing a step somewhere. I have set the name column in spells.2da to ****, and was wondering if i need to use that column to somehow link it to my entry in forceshields.2da? Or maybe edit the k_sup_bands impactscript specified in th spells.2da to recognise my new entry? Or anything else you can think of.
Of course there is always the possibility that it is impossible to add a new energy shield to KOTOR. If that is the case, please let me know also!
You must edit the k_sup_bands impactscript. Add a new entry to the script and use the SubtypeID of the new shield's uti-file as the spellID. You must also use the shield's index number in the forceshields.2da as nShield in the script instead of the label unless you want to edit nwscript.nss. You can also choose which effect icon you want to use for the new shield and the shield's duration by editing k_sup_bands.nss.
Ok, I have tried all of that, and now no shield appears at all. The animation to activate the shield plays, but no shield appears and there is no indicator on the portrait of an enhancement being used.
Ok, I have tried all of that, and now no shield appears at all. The animation to activate the shield plays, but no shield appears and there is no indicator on the portrait of an enhancement being used.
Sounds like the impact script is not running properly, that way the character would activate the item but nothing would then happen since the script deals with what happend after that. Post the script you use and perhaps someone can spot what's wrong.
Also, if you make your own shield I'd recommend against modifying the k_sup_bands.ncs script, that would just make it harder for your mod to be compatible with others that tweak armbands. Make your own impact script instead and set it in the impactscript column for your line in spells.2da.
I created a new script as you suggested stoffe, and it is working perfectly now. Thanks for the assist.