Jump to content

Home

Some questions on scripting


Soulforged

Recommended Posts

Casting feat, yeah?

void main ()
{
object oFeatUser = [color=green]OBJECT_SELF[/color];
object oTarget = [color=yellow]OBJECT_SELF[/color];
talent tPowerAttack = TalentFeat([color=green]FEAT_POWER_ATTACK[/color]);
   ActionUseTalentOnObject(tPowerAttack, oTarget);
}

Here, FEAT_POWER_ATTACK is feat constant taken from nwscript.nss

Also you may just use row number from feats.2da as this constant.

OBJECT_SELF is feat user, you may change from OBJECT_SELF to GetFirstPC(), this is player. Or GetObjectByTag("object_tag") to get object with the specified tag. So any object you want. the same is with OBJECT_SELF, but OBJECT_SELF is feat's target.

Hope it helps you.

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...