Jump to content

Home

Picture this scene...


goldberry

Recommended Posts

I have two Sith standing in the middle of Tarris Upper City South (Renamed Yavin 4 Slums), a master, and an apprentice. The master is a "Predator", and the apprentice is "neutral". I have it so that when you talk to the apprentice, he babbles on about being stronger than his master, and that one day he will *be* the master. The master has a series of choices you make in his dialogue, and if you choose the right ones, I have the apprentice change from "Neutral" to "prey".

 

When the apprentice kills the master, I want his dialogue to change to something like "hahahaha! I am the master now!", how would I do this?

 

p.s. I then hope to expand it so you can bad mouth him, and fight, and kill, him.

Link to comment
Share on other sites

I modified my script above as part of it was uneeded.

 

If you look at the npc .utc file, you should see a field called OnDeath. This is where you have to attach your script so it is fired when the npc dies.

 

You will find more on Creature events and USerDefined events here:

http://nwn.bioware.com/forums/viewcodepost.html?post=762559

http://nwn.bioware.com/forums/viewcodepost.html?post=762682

(It's for nwn but it applies to Kotor as well)

 

This part: AssignCommand((GetObjectByTag("my_npc_tag")) assigns a command to your other npc when the master dies. Replace my_npc_tag by the apprentice's tag.

 

Then this part: ActionStartConversation(GetFirstPC(), "my_dlg", FALSE, CONVERSATION_TYPE_CINEMATIC, TRUE));

Tells the npc to start conversation with the pc: ActionStartConversation(GetFirstPC(),

Tells thew npc which .dlg to use: "my_dlg" (replacemy_dlg with the resref of the .dlg file you want to use.

FALSE indicates that it is not a private converstation.

CONVERSATION_TYPE_CINEMATIC: the type of conversation, the other choice being CONVERSATION_TYPE_COMPUTER which gives you the computer interface.

and finally TRUE: since you mentioned that it was for use after a battle, this will start the conversation "without requiring to close the distance between the two object in dialog".

 

Look at nwscript.nss for more details.

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...