lfnetwork.com mark read register faq members calendar

Thread: SET_NAVGOAL question
Thread Tools Display Modes
Post a new thread. Add a reply to this thread. Indicate all threads in this forum as read. Subscribe to this forum. RSS feed: this forum RSS feed: all forums
Old 08-28-2004, 01:44 AM   #1
JavaGuy
 
JavaGuy's Avatar
 
Join Date: Aug 2002
Posts: 141
SET_NAVGOAL question

I have a script that sets an Reborn NPC's nav goal during a cinematic when the NPC is first triggered. No problem...he walks right to it, then activates his sabre, very dramatic.

But then I want the Reborn to jump (or at least run over to) a certain nav goal when the player walks through a certain trigger. So the trigger is inactive at first, then activated when the Reborn spawns, and targets a scriptrunner that runs this script:

affect ( get( STRING, "SET_PARM1"), /*@AFFECT_TYPE*/ FLUSH )
{
task ( "goto" )
{
set ( "SET_BEHAVIORSTATE", "BS_CINEMATIC" );
set ( "SET_NAVGOAL", get( STRING, "SET_PARM2") );
}

do ( "goto" );
}


Now...nothing happens!

Before you ask...

Yes, I'm sure the script gets run. The Reborn does indeed enter cinematic state and stop fighting when I walk through the trigger. He just doesn't go the the nav goal.

Yes, parm2 on the script runner is set to the targetname (not the script_targetname) of the nav goal.

Any suggestions?

Thanks in advance,
Sam
JavaGuy is offline   you may: quote & reply,
Old 08-29-2004, 11:01 PM   #2
Mercenary
 
Mercenary's Avatar
 
Join Date: Jun 2002
Posts: 381
I don't know about this parm stuff, I find it just complicates things. It's best to use names and descriptions that mean something. Just give your NPC an NPC_targetname and use his name in the affect statement. Change the "do" to a "dowait"

If you want your NPC to jump to a navgoal you have to change his behavior state to BS_JUMP.
Mercenary is offline   you may: quote & reply,
Old 08-30-2004, 02:53 PM   #3
lassev
cryptoscripter
 
lassev's Avatar
 
Join Date: Jun 2002
Location: Finland
Posts: 1,087
The reborn needs to have the parm2, not the script_runner. If you affect the reborn, then the parm2 is retrieved from his properties.


Frozen by ICARUS
lassev is offline   you may: quote & reply,
Old 08-31-2004, 06:55 AM   #4
JavaGuy
 
JavaGuy's Avatar
 
Join Date: Aug 2002
Posts: 141
I'm using PARMs because I'm going to have a bunch of these and don't want to write a bunch of scripts that are all identical except for a few target names.

I think lassev has hit upon the answer--It's the NPCs PARM it gets because the Affect essentially creates a new script and pushes it off on the NPC. I'll test it as soon as I get home. Good catch, and thanks!

What I'll probably do is grab the value from the scriptrunner and put it in a global variable.
JavaGuy is offline   you may: quote & reply,
Post a new thread. Add a reply to this thread. Indicate all threads in this forum as read. Subscribe to this forum. RSS feed: this forum RSS feed: all forums
Go Back   LucasForums > Network > JediKnight Series > Editing Central > JO Mapping > SET_NAVGOAL question

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 06:30 AM.

LFNetwork, LLC ©2002-2011 - All rights reserved.
Powered by vBulletin®
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.