When the pc enters a module (eg: Endar Spire), how can I get the pc to instantly start a dialog with an npc (eg: Trask, with TagResRef: trask)?
Please post answers as I leave my work in the middle waiting for answers...
Thank you.
Nick-Vader.
In the onenter slot for the module. It can be found in the ARE file.
You put in a script like:
void main() {
object oNPC=GetObjectByTag("npc_tag");
location lMe=GetLocation(GetFirstPC());
ActionDoCommand(SetCommandable(TRUE,oNPC));
AssignCommand (oNPC,ActionForceMoveToLocation(lMe,FALSE));
AssignCommand (oNPC, ActionStartConversation(GetFirstPC()));
}
In than npc's utc file put in the name for the dialog in the conversation slot.
In the onenter slot for the module. It can be found in the ARE file.
You put in a script like:
void main() {
object oNPC=GetObjectByTag("npc_tag");
location lMe=GetLocation(GetFirstPC());
ActionDoCommand(SetCommandable(TRUE,oNPC));
AssignCommand (oNPC,ActionForceMoveToLocation(lMe,FALSE));
AssignCommand (oNPC, ActionStartConversation(GetFirstPC()));
}
In than npc's utc file put in the name for the dialog in the conversation slot.
Thnx. I thought I'd have to wait for days to get an answer !:thmbup1: