25 lines
602 B
Plaintext
25 lines
602 B
Plaintext
|
void main()
|
||
|
{
|
||
|
|
||
|
|
||
|
|
||
|
object oPC = GetEnteringObject();
|
||
|
|
||
|
// replace this tag string with the tag string of your NPC.
|
||
|
object oNPC = GetNearestObjectByTag("bathdoor");
|
||
|
|
||
|
{
|
||
|
|
||
|
// check to make sure NPC isn't already talking to somebody.
|
||
|
if (!IsInConversation(oNPC)) {
|
||
|
|
||
|
// stop whatever we were already doing.
|
||
|
AssignCommand(oNPC, ClearAllActions());
|
||
|
|
||
|
|
||
|
// start talking to PC.
|
||
|
AssignCommand(oNPC, ActionStartConversation(oPC));
|
||
|
}
|
||
|
}
|
||
|
}
|