Skip to content
Permalink
Browse files

Fix problem with Ch. 6 component on BG1

The Ch. 6 Restored Dialogues component would not install correctly on BG1-TotSC. BG1 ACTIONS.IDS file does not have "Dialog" as alias for "Dialogue" and BG1 engine does not support AreaCheck trigger.

Thanks to suggestion from Jastey, using a variable set by area script to simulate an AreaCheck().

See: http://forums.pocketplane.net/index.php/topic,29712.msg339285.html#msg339285
  • Loading branch information...
AstroBryGuy committed May 11, 2018
1 parent f9079fd commit c2d4b7f3fd475c0af18b8a5cc50e17923c7106d4
Showing with 25 additions and 5 deletions.
  1. +8 −0 bg1ub/ch6/bg1ub_ch6.tpa
  2. +6 −0 bg1ub/ch6/ub2612_bg1.baf
  3. +6 −0 bg1ub/ch6/ub2614_bg1.baf
  4. +5 −5 bg1ub/ch6/ubch6.d
@@ -1,6 +1,14 @@
/////Chapter 6 Dialogue Restorations
/////by AstroBryGuy

ACTION_IF GAME_IS ~bg1 totsc~ THEN BEGIN
OUTER_SPRINT AreaCheckAR2614 ~Global("UBAreaCheckAR2614","GLOBAL",1)~
LAF extend_area_script STR_VAR area="%Candlekeep_Library_L5%" bottom="bg1ub/ch6/ub2612_bg1.baf" END
LAF extend_area_script STR_VAR area="%Candlekeep_Library_L6%" bottom="bg1ub/ch6/ub2614_bg1.baf" END
END ELSE BEGIN
OUTER_SPRINT AreaCheckAR2614 ~AreaCheck("%Candlekeep_Library_L6%")~
END

/* Area script changes */
LAF extend_area_script STR_VAR area="%Candlekeep_Library_L1%" bottom="bg1ub/ch6/ubmurder.baf" END
LAF extend_area_script STR_VAR area="%Candlekeep_Library_L2%" bottom="bg1ub/ch6/ub2609.baf" END
@@ -0,0 +1,6 @@
IF
Global("UBAreaCheckAR2614","GLOBAL",1)
THEN
RESPONSE #100
SetGlobal("UBAreaCheckAR2614","GLOBAL",0)
END
@@ -0,0 +1,6 @@
IF
Global("UBAreaCheckAR2614","GLOBAL",0)
THEN
RESPONSE #100
SetGlobal("UBAreaCheckAR2614","GLOBAL",1)
END
@@ -10,20 +10,20 @@ APPEND ~%tutu_var%tethto2~
DO ~SetGlobal("UBTethtorilCh6","GLOBAL",2)~ GOTO UBTethtorilNoSurrender
IF ~~ THEN REPLY @4
DO ~SetGlobal("UBTethtorilCh6","GLOBAL",2)~ GOTO UBTethtorilNoSurrender
IF ~~ THEN REPLY @5
DO ~SetGlobal("UBTethtorilCh6","GLOBAL",2) CreateCreature("%tutu_var%WATCH6",[1050.850]%FACE_0%) ActionOverride("%tutu_var%WATCH6",MoveToObject(Player1)) ActionOverride("%tutu_var%WATCH6",Dialog(Player1))~ EXIT
IF ~~ THEN REPLY @5
DO ~SetGlobal("UBTethtorilCh6","GLOBAL",2) CreateCreature("%tutu_var%WATCH6",[1050.850]%FACE_0%) ActionOverride("%tutu_var%WATCH6",MoveToObject(Player1)) ActionOverride("%tutu_var%WATCH6",Dialogue(Player1))~ EXIT
END
IF ~~ THEN BEGIN UBTethtorilNoSurrender
SAY @6
IF ~~ THEN DO ~CreateCreature("%tutu_var%WATCH6",[1050.850]%FACE_0%) ActionOverride("%tutu_var%WATCH6",MoveToObject(Player1)) ActionOverride("%tutu_var%WATCH6",Dialog(Player1)) EscapeArea()~ EXIT
IF ~~ THEN DO ~CreateCreature("%tutu_var%WATCH6",[1050.850]%FACE_0%) ActionOverride("%tutu_var%WATCH6",MoveToObject(Player1)) ActionOverride("%tutu_var%WATCH6",Dialogue(Player1)) EscapeArea()~ EXIT
END
END

/* Gatewarden shouldn't accuse CHARNAME of killing Thaldorn */
REPLACE_SAY ~%tutu_var%gatewa2~ 2 @7

/* Replies to WATCH6.CRE won't include reference to Ulraunt and Tethtoril if CHARNAME is on the 6th floor */
ADD_TRANS_TRIGGER ~%tutu_var%watch6~ 0 ~!AreaCheck("%Candlekeep_Library_L6%")~ DO 1
ADD_TRANS_TRIGGER ~%tutu_var%watch6~ 0 ~!%AreaCheckAR2614%~ DO 1
EXTEND_BOTTOM ~%tutu_var%watch6~ 0
IF ~AreaCheck("%Candlekeep_Library_L6%")~ THEN REPLY @8 GOTO 2
IF ~%AreaCheckAR2614%~ THEN REPLY @8 GOTO 2
END

0 comments on commit c2d4b7f

Please sign in to comment.
You can’t perform that action at this time.