Jump to content

Home

[TSL]armband


Recommended Posts

Here, the basic way to do it involves Spells.2da editing... Only way I know how is I've been editing Darth333's spawnband lately to figure out how you make such a thing.

 

You have to edit your spells.2da to create a new line in it (I don't know what it is for TSL) I don't know what you'll have to call it, check out the shields for help. Then, see the runscript or something like that heading? Under that you'll want to insert the name of your script (E.G. myscript) no .ncs. Then you'll want to create your script so that it spawns a creature around you. (Don't ask me, I can't script to save my life).

 

At least... I think that's how it works!

 

If you want D333's Spawnband, just PM me for it... or her...

Link to comment
Share on other sites

You can use this as your script and in the Script Parameters, "P1" collumn you put the distance away from the PC you want the target to spawn in meters, like "5", and in the String Param collumn you can put the object ResRef you want to spawn, like if you want a rancor you put "c_rancor".

This way you can use this script on all of your dialog nodes and only need to change your "P1" and "String Param".

void main(){
object oPC = GetFirstPC();
int iDistance = GetScriptParameter(1);
string sCreatureTemplate = GetScriptStringParameter();

vector vPC = GetPosition(oPC);
float fFacing = GetFacing(oPC);
float fDistance = IntToFloat(iDistance);
vector vFacing = AngleToVector(fFacing);
vector vSpawn = vFacing * fDistance;
location lSpawn = Location(vSpawn, 0.0);

object oSpawn = CreateObject( OBJECT_TYPE_CREATURE, sCreatureTemplate, lSpawn, TRUE );

AssignCommand( oSpawn, SetFacingPoint(vPC) );
AssignCommand( oSpawn, ActionAttack(oPC, FALSE) );
}

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...