Note: LucasForums Archive Project
The content here was reconstructed by scraping the Wayback Machine in an effort to restore some of what was lost when LF went down. The LucasForums Archive Project claims no ownership over the content or assets that were archived on archive.org.

This project is meant for research purposes only.

Little help here?

Page: 1 of 1
 GeorgNihilus
01-05-2010, 8:53 PM
#1
Hey there, again ... :)

I'm using this script to make an NPC go where I want to before vanishing, it's working as I want except for the fact that I can interact with her with the R key while she walks.

void ST_Move() {
SetCommandable(TRUE);
ActionMoveToLocation(Location(Vector(-32.9496, 14.387, 0.0000), 99.555));
// ActionDoCommand(SetFacingPoint(Vector(-8.13, 92.12, 12.75)));
}

void ST_Move2() {
SetCommandable(TRUE);
ActionMoveToLocation(Location(Vector(-32.2602, 20.4693, 0.0000), 67.727));
}

void ST_Move3() {
SetCommandable(TRUE);
ActionMoveToLocation(Location(Vector(-13.0738, 21.9828, 0.0000), 355.40));
}

void ST_Move4() {
SetCommandable(TRUE);
ActionMoveToLocation(Location(Vector(-6.08876, 5.60771, 0.0000), 286.197));
}

void main() {
DelayCommand(6.0, AssignCommand(GetObjectByTag("meganfox"), ST_Move()));
DelayCommand(11.4, AssignCommand(GetObjectByTag("meganfox"), ST_Move2()));
DelayCommand(14.2, AssignCommand(GetObjectByTag("meganfox"), ST_Move3()));
DelayCommand(20.2,AssignCommand(GetObjectByTag("meganfox"), ST_Move4()));
DelayCommand(22.4, DestroyObject(GetObjectByTag("meganfox")));

}

There's a script in the game (TSL) named a_exit_walk which exits the area AND somehow keeps the PC from interacting with the NPC as he/she exits ...

so, how can I edit the previous script to exit not from the default module exit but from a spot I select? :raise:

thanks on advance as usual :thmbup1:
 Star Admiral
01-06-2010, 7:40 PM
#2
Not sure if I followed the a_exit_walk.nss script completely, but try the following.

void ST_Move() {
ActionMoveToLocation(Location(Vector(-32.9496, 14.387, 0.0000), 99.555));
}

void ST_Move2() {
ActionMoveToLocation(Location(Vector(-32.2602, 20.4693, 0.0000), 67.727));
}

void ST_Move3() {
ActionMoveToLocation(Location(Vector(-13.0738, 21.9828, 0.0000), 355.40));
}

void ST_Move4() {
ActionMoveToLocation(Location(Vector(-6.08876, 5.60771, 0.0000), 286.197));
}

void main() {
object oTarget = GetObjectByTag("meganfox");
SetCommandable(TRUE, oTarget);
DelayCommand(6.0, AssignCommand(oTarget, ST_Move()));
DelayCommand(11.4, AssignCommand(oTarget, ST_Move2()));
DelayCommand(14.2, AssignCommand(oTarget, ST_Move3()));
DelayCommand(20.2, AssignCommand(oTarget, ST_Move4()));
DelayCommand(22.4, AssignCommand(oTarget, DestroyObject(oTarget)));
DelayCommand(22.5, AssignCommand(oTarget, SetCommandable(FALSE, oTarget)));
}

- Star Admiral
Page: 1 of 1