PDA

View Full Version : Those interrupting little party members


Doc Valentine
01-07-2005, 05:07 AM
Hey, got another technical question for my mod. How do i make on of the party members i have jumpt into a convo im having with another npc and then have them not jump in when they are not there?

tk102
01-07-2005, 05:40 AM
Use the Speaker field with NPC's tag. If the NPC isn't present the dialog will fall to the next possible Entry. So be sure to have a backup Entry that keeps your dialog connected.
Edit: Use conditional scripts to check for the presence of the NPCs as described below

Tanesh
01-07-2005, 05:43 AM
The scripts do already extist in KotOR. Check with the Kotor Tool BIFs -> scripts.bif -> scripts, source.

For example for Bastila, the script is named k_con_bastilapm.


//:: k_con_bastilapm
/*
checks to see if bastila is a party member
*/
//:: Created By:
//:: Copyright (c) 2002 Bioware Corp.
//:: modified by Aidan, Sept 28,02
//:: updated with the new party functions
#include "k_inc_debug"

int StartingConditional()
{
return ((IsNPCPartyMember(NPC_BASTILA) == TRUE) && (GetDistanceBetween(GetPCSpeaker(), GetObjectByTag("bastila")) <= 10.0));
}


For the others, it's k_con_candpm, k_con_carthpm etc.

You must add the name in the field "Script that determines if node is available". That should do the job. :)

T7nowhere
01-07-2005, 11:22 AM
ya, you need both the con script and speaker tag. The script(goes in the determines availibility box) will check to see if the NPC is with you and if he/she is then the speaker tag will determine who the to point the Camera towards and who needs the lipsync if specified.

tk102
01-07-2005, 11:48 AM
Are you sure the conditional script is needed? After looking through a lot of dialogs lately (;)) it seems that conditions weren't used everywhere... for example when departing the unknown world, if Juhani is not present (ie. you killed her on Dantooine) then her lines get spoken by Jolee. No conditional script (that I remember) was used -- just a backup dialog branch.

Tanesh
01-07-2005, 12:39 PM
I am sure. At the temple, it's the script k_con_juhanilive and after escaping the Leviathan it's k_ebo_chkjuhani , for example.

tk102
01-07-2005, 01:00 PM
Thank you for the clarification Tanesh. I apologize to all for the misinformation.