Recent changes Random page
GAMING
Gaming
 
WoWWiki
Halopedia
FFXIclopedia
Age of Conan
Warhammer Online
Grand Theft Wiki
See more...

Make a NPC flee the area after a conversation

From NWNWiki

Jump to: navigation, search

[edit] Make a NPC flee the area after a conversation

Place a Waypoint located where you want the NPC to move to and vanish. Give it a Unique Tag. Note: there is a default tag called "NW_EXIT". however, if you use this a lot, the NPC could get confused and move to the wrong one.

In the Conversation Editor, Click on the last TAB in the lower right "Current File". Place this script in the "End Conversation Normally" script handle. You can also place it in the "Aborted" handle if you like.

#include "nw_i0_plot"
void main()
{
    // Change FALSE to TRUE if you want the NPC to Run.
    // If you use the default Waypoint Tag of "NW_EXIT"
    // then all you need is EscapeArea();
    // Or, EscapeArea(TRUE); if you want him to Run.
    EscapeArea(FALSE, "Waypoint_Tag");
}
Rate this article:
Share this article: