diff --git a/data/campaigns/The_Hammer_of_Thursagan/scenarios/09_Forbidden_Forest.cfg b/data/campaigns/The_Hammer_of_Thursagan/scenarios/09_Forbidden_Forest.cfg index e4856d73b41d..a3112ececa5c 100644 --- a/data/campaigns/The_Hammer_of_Thursagan/scenarios/09_Forbidden_Forest.cfg +++ b/data/campaigns/The_Hammer_of_Thursagan/scenarios/09_Forbidden_Forest.cfg @@ -254,6 +254,7 @@ [/move_unit_fake] [/event] + # Angarthing and Aiglondur speak when they reach the signpost. [event] name=moveto first_time_only=yes @@ -261,28 +262,10 @@ id=Aiglondur x,y=40,17 [/filter] - - [message] - speaker=Aiglondur - message= _ "Rally on me, everyone. We have better things to do than brawl with elves." - [/message] - - [if] - [variable] - name=angarthing_passed - equals=yes - [/variable] - [then] - [endlevel] - result=victory - bonus=yes - {NEW_GOLD_CARRYOVER 40} - [/endlevel] - [/then] - [else] - {VARIABLE aiglondur_passed yes} - [/else] - [/if] + [fire_event] + name=Aiglondur message + [/fire_event] + [allow_undo][/allow_undo] [/event] [event] @@ -292,34 +275,65 @@ id=Angarthing x,y=40,17 [/filter] + [fire_event] + name=Angarthing message + [/fire_event] + [allow_undo][/allow_undo] + [/event] + + [event] + name=Aiglondur message + first_time_only=yes + [message] + speaker=Aiglondur + message= _ "Rally on me, everyone. We have better things to do than brawl with elves." + [/message] + [/event] + [event] + name=Angarthing message + first_time_only=yes [message] speaker=Angarthing message= _ "Kal Kartha should be only another day’s march east of here." [/message] - - [if] - [variable] - name=aiglondur_passed - equals=yes - [/variable] - [then] - [endlevel] - result=victory - bonus=yes - {NEW_GOLD_CARRYOVER 40} - [/endlevel] - [/then] - [else] - {VARIABLE angarthing_passed yes} - [/else] - [/if] [/event] [event] - name=scenario_end - - {CLEAR_VARIABLE aiglondur_passed,angarthing_passed} + name=moveto + first_time_only=no + [filter_condition] + [have_unit] + id=Aiglondur + x,y=40,17 + [filter_adjacent] + id=Angarthing + [/filter_adjacent] + [/have_unit] + [or] + [have_unit] + id=Angarthing + x,y=40,17 + [filter_adjacent] + id=Aiglondur + [/filter_adjacent] + [/have_unit] + [/or] + [/filter_condition] + + # If Aiglondor is on the signpost and Angarthing next to him, or the other way around, + # the player has won. Fire Aiglondur's and Angarthing's messages if they haven't fired yet. + [fire_event] + name=Aiglondur message + [/fire_event] + [fire_event] + name=Angarthing message + [/fire_event] + [endlevel] + result=victory + bonus=yes + {NEW_GOLD_CARRYOVER 40} + [/endlevel] [/event] {HERODEATH_AIGLONDUR}