Jump to content

Home

Conditional Dialog Scripts


MasterWaffle

Recommended Posts

I used this script to check if Kreia was present in my Mechanical hand mod:

 

int StartingConditional()
{
 return(IsNPCPartyMember([b]NPC_KREIA[/b]) == TRUE) && (GetDistanceBetween(GetPCSpeaker(), GetObjectByTag("[b]Kreia[/b]")) <= 25.0);
}

 

Change NPC_KREIA to the particular party member you want to check for and then change Kreia to the tag of the party member you want to check for.

 

And you wont need the other script as if the party member isn't present the NPC speaking the conversation will move onto the next node, the one where the party member won't be there.

Link to comment
Share on other sites

... Change NPC_KREIA to the particular party member you want to check for and then change Kreia to the tag of the party member you want to check for...

I'm not sure what the name of the particular party member is. I put:

 

int StartingConditional()

{

return(IsNPCPartyMember(Party_NPC_Mission) == TRUE) && (GetDistanceBetween(GetPCSpeaker(), GetObjectByTag("Mission")) <= 25.0);

}

And I get a bunch of errors when I try to compile. I have no doubt I'm doing something wrong.

 

I'm not a scripting expert, but if you look at the dialog files, you'll find the names of scripts in dialogs that use party members. Eg: Motta's dialog. That's what I do whenever I need a script like that.

I would do that, but the scripts are for KotOR 1, so they won't decompile (least I think they won't). And I can't read compiled scripts. At all.

Link to comment
Share on other sites

ETA: It doesn't seem to work. It fires the node without the script, even if Mission is in my party.

 

You have to have the node with the script connected above the one without it, as conversations work like cues, if the first node will run without a script then that will be the the node the conversation will go on.

Link to comment
Share on other sites

AFAIK that should work, there must be something you're doing wrong, try having them as completely separate nodes and see if that works, but it should be working.

 

Unfortunately it isn't. I'll just start over at this point, see if it's the file. Thanks for all your help. :)

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...