http://www.finhosting.fi/~fallout/screenshots/dialogueissue.gif . Note that it is top-level.
In addition, I have another top-level topic which allows the player to pass the NPC additional stimpacks.
The annoying thing is this.
I use the pass-NPC-additional-stimpacks option, and it works properly, and I can see through console that the additional stimpacks were added to the NPCs inventory. But if after I do that, when immedietely I select the "ask about stimpacks" dialogue option, it has not re-evaluated the inventory, and the response I get matches the stimpack count from before I passed him more stimpacks. If I then select the "ask about stimpacks" option a second time, it re-evaluates and reports the right number. So, in effect I have to ask twice if I add more stimpacks, or I will get a stupid answer.
One workaround I tried was thwarted due to something sorta goofy. I was able to make the pass-additional-stimpacks option a goodbye line, which would force the player to open dialogue anew with the NPC, which would force the re-evaluation to happen. But this had a problem. I *think* because this is both top-level and goodbye, it caused the dialogue to somewhat hang on exit (it is an unvoiced topic at this time). The game is forcing the player to click off on the goodbye line before dialogue will exit, and if the player does not click, it will sit forever. I decided that this situation was too ugly to keep.
Another thing I tried was specifying topics as the "choices" for the pass-additional-stimpacks dialog option, and trying to omit the "how many stimpacks do you have" question from that list. It seemed to ignore my "choices" list in this case - no matter what it was showing the original set of dialogue topics. I tried this both with "info refusal" selected and unselected, and it didn't care. I am not sure why it wouldn't show my choices, maybe I did something stupid?
I suspect that I could probably move this to be a nested topic and have it work alright because using "goodbye" might work properly, then. But I really need it top-level.
What I really want is to force this thing to re-evaluate the conditions of these topics first-shot. If anyone has any ideas, I'm all ears.