Jump to content

"Make Khalid a Fighter-Mage": Khalid dialogue loops.


Recommended Posts

In "dlg/p#khalid.d", the variable "P#KhalidMage" needs to be increased to stop Khalid from repeating the dialogue:

APPEND ~%KHALID_BANTER%~

IF WEIGHT #-2 ~
Global("P#KhalidMage","GLOBAL",2)~ THEN BEGIN KHMAGE1
SAY @0
++ @1 + KHMAPC1.1
+~!Class(Player1,FIGHTER_MAGE)~+ @2 + KHMAPC1.2
+~Class(Player1,FIGHTER_MAGE)~+ @3 + KHMAPC1.2M
+~Class(Player1,FIGHTER_ALL) Race(Player1, HUMAN) CheckStatGT(Player1,16,INT)~+ @4 + KHMAPC1.2F
++ @5 + KHMAPC1.3
+~InParty("jaheira")~+ @6 + KHMAPC1.4
END

should have a "SetGlobal("P#KhalidMage","GLOBAL",3)" for all reply options.

Link to comment

If I'd like to use this fix before it gets included in the next Tweaks Anthology release, would I change the code to the below?

APPEND ~%KHALID_BANTER%~

IF WEIGHT #-2 ~
Global("P#KhalidMage","GLOBAL",2)~ THEN BEGIN KHMAGE1
SAY @0
++ @1 + KHMAPC1.1
+~!Class(Player1,FIGHTER_MAGE)~+ @2 + KHMAPC1.2
+~Class(Player1,FIGHTER_MAGE)~+ @3 + KHMAPC1.2M
+~Class(Player1,FIGHTER_ALL) Race(Player1, HUMAN) CheckStatGT(Player1,16,INT)~+ @4 + KHMAPC1.2F
++ @5 + KHMAPC1.3
+~InParty("jaheira")~+ @6 + KHMAPC1.4
SetGlobal("P#KhalidMage","GLOBAL",3 // added line
END

 

Edited by testlum
Link to comment

The SetGlobal needs to be added to each transaction separately, like this:

IF WEIGHT #-2 ~
Global("P#KhalidMage","GLOBAL",2)~ THEN BEGIN KHMAGE1
SAY @0
++ @1 DO ~SetGlobal("P#KhalidMage","GLOBAL",3)~ + KHMAPC1.1
+~!Class(Player1,FIGHTER_MAGE)~+ @2 DO ~SetGlobal("P#KhalidMage","GLOBAL",3)~ + KHMAPC1.2
+~Class(Player1,FIGHTER_MAGE)~+ @3 DO ~SetGlobal("P#KhalidMage","GLOBAL",3)~ + KHMAPC1.2M
+~Class(Player1,FIGHTER_ALL) Race(Player1, HUMAN) CheckStatGT(Player1,16,INT)~+ @4 DO ~SetGlobal("P#KhalidMage","GLOBAL",3)~ + KHMAPC1.2F
++ @5 DO ~SetGlobal("P#KhalidMage","GLOBAL",3)~ + KHMAPC1.3
+~InParty("jaheira")~+ @6 DO ~SetGlobal("P#KhalidMage","GLOBAL",3)~ + KHMAPC1.4
END

 

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.

Guest
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...