Jump to content

Home

How do I stop Using force powers on myself?


mgnails

Recommended Posts

all of them. I am making a mod that turns all hostile powers into friendly ones so you can use them on non-hostile NPC's, One of which includes force jump but I keep using these powers on myself. How did you make yours friendly and not have them be used on yourself Darth Khasei?

Link to comment
Share on other sites

Use the GetIsFriend function as in

if (!GetIsFriend(oTarget) {
//spell!
}

This differs from the normal hostile force power that uses:

if (GetIsEnemy(oTarget) {
// spell!
} 

You will not be able to kill your party NPCs, but you will also not kill yourself.

Link to comment
Share on other sites

Dang, thought I could do it without scripting as the force powers all end up in the friendly spot after spells.2da editing. Anyways, do these force powers have .nss files somewhere because I don't think .ncs is editable.

Link to comment
Share on other sites

In spells.2da there's a field called impactscript and that's the script that gets called. For most it's k_sp1_generic and that script has k_inc_force as its include script which is where all the powers are handled. The source is in scripts.bif.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...