Ok... I don't have time to give you a whole lot here, DJW, but the good news is TimBob12 has a great tutorial on conditional scripts that will help you here.
It is certainly possible to check if an NPC or the PC has a certain item equipped
, and probably but not certain (for me) you can check if it is in the PC inventory period.
Think about the steps.
1. You need to "get" the individual in question.
2. You need to check for the item on said individual.
3. You need to return the value to the dialog to open or close the branch in question.
so, off the top of my head, and I may improve this later at a real PC with KTool, but... and I bet there is an in-game function for this so that we don't have to create one (came to me as I wrote my "name" for the conditional function, and it seemed oddly familiar):
object oPC = GetObjectByTag(yourNPCtag);
That might work, or something along those lines. KotOR Tool itself has a helpful script editor search window that you can just randomly type words into, like "equip" "item" "has" etc.... never know what that can bring up
As to the goodbye function... dunno... Never looked at it. Guess I'm curious though, so I will look at it. EDIT: goodbye "function". What are you referring to? is it a script in-game? There is no function in nwscript called "goodbye"