Posted by: DavidW
« on: May 08, 2022, 03:13:19 PM »And presumably it shouldn't. In variable-substitution contexts a file is just text. (I substitute comments in and out in various bits of my code.)
However, WeiDU is evaluating %WNL% even if it is commented out. That was causing my error above because I commented out lines of unused code while I was troubleshooting.
<<<<<<<<./narlen.d
//REPLACE_TRIGGER_TEXT NARLEN ~Global("TalkedToNarlen","GLOBAL",0)\([ %TAB%%WNL%]+!\)~ ~Global("TalkedToNarlen","GLOBAL",0) !InParty([0.0.0.BARD_ALL]) \1~
REPLACE_TRIGGER_TEXT NARLEN ~Global("TalkedToNarlen","GLOBAL",0)\([ %TAB%%WNL%]+!\)~ ~Global("TalkedToNarlen","GLOBAL",0) !InParty([0.0.0.BARD_ALL]) \1~
>>>>>>>>
COMPILE ~./narlen.d~ EVALUATE_BUFFER
Removing the commented code, or wrapping it in /* */ instead works fine. OUTER_SPRINT monegate ~!~
///////////////////////////////////////////////////////////////////////////
// Narlen Darkwalk - BGEE Thieves Guild //
///////////////////////////////////////////////////////////////////////////
ACTION_IF GAME_IS ~bgee eet~ BEGIN
COMPILE EVAL ~skills-and-abilities/dlg/narlenb.d~
END
REPLACE_TRIGGER_TEXT NARLEN ~Global("TalkedToNarlen","GLOBAL",0)[ %TAB%%WNL%]*%monegate%~ ~Global("TalkedToNarlen","GLOBAL",0) !InParty([0.0.0.BARD_ALL]) !~
OUTER_SPRINT NEGATE ~!~
and add EVAL to the COMPILE action.REPLACE_TRIGGER_TEXT NARLEN ~Global("TalkedToNarlen","GLOBAL",0)[ %TAB%%WNL%]*%NEGATE%~ ~Global("TalkedToNarlen","GLOBAL",0) !InParty([0.0.0.BARD_ALL]) !~
Global("TalkedToNarlen","GLOBAL",0)
!InParty([0.0.0.THIEF_ALL])
Global("TalkedToNarlen","GLOBAL",0)
REPLACE_TRIGGER_TEXT NARLEN ~Global("TalkedToNarlen","GLOBAL",0)[ %TAB%%LNL%%MNL%%WNL%]*!~ ~Global("TalkedToNarlen","GLOBAL",0) !InParty([0.0.0.BARD_ALL]) !~