Jump to content

Dialogue not triggering in my NPC mod


Recommended Posts

Hello, I'm trying to learn about modding so as a starting point I made a test npc following Lava's guide here:


Everything works fine except for one dialogue that doesn't trigger. I can remove the character from the group without problems. But If I speak to the character again (to rejoin) the dialogue appearing it's the same one that appears when I kicked the character.

Here is the link if someone has time to check the archives and tell me what I doing wrong:

 https://www.dropbox.com/s/5xo21t3uvvdtghg/npc test 1.zip?dl=0

If I had to guess the problems seems to be the "BEGIN Z9MAIEVP" part and I tried some changes (without knowing what was I doing , of course) without success.

I used Notepad2, EEKeeper and Weidu 246. The NPC appears in Candlekeep (close to charname) for easy and quick test.


Link to comment

Sorry to bump this again but I just realized I had some unexpected behaviour. Since I assumed the problem was the LOCALS I just change both  for GLOBAL leaving:


IF~~THEN REPLY ~Yes. Goodbye.~ DO ~SetGlobal("Z9MAIEVJoin","GLOBAL",0)~ EXIT
IF~~THEN REPLY ~No. It’s just a mistake. Come, we should be moving.~ DO ~JoinParty()SetGlobal("Z9MAIEVJoin","GLOBAL",1)~ EXIT


Now, the initial dialogue works, the kickout works and the rejoins works too. But, if I add the character to the party again (after the initial kick) and kick it again the dialogue that appears is the rejoin one.

Link to comment

Always do JoinParty() last in the action list. The SetGlobal should be before that, or it will not be executed, at least not reliably.

These actions should always be last (there might be more):






For you this means, use this and see whether it might solve your problem:

IF~~THEN REPLY ~No. It’s just a mistake. Come, we should be moving.~ DO ~SetGlobal("Z9MAIEVJoin","GLOBAL",1) JoinParty()~ EXIT


Link to comment

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...