TSG S7a: duplicate less WML
use monstrous event instead of monstrous macro [ci skip]
This commit is contained in:
parent
59b205a404
commit
9717743f74
1 changed files with 83 additions and 79 deletions
|
@ -388,90 +388,92 @@
|
|||
{VARIABLE troll_help_cost 150}
|
||||
#endif
|
||||
|
||||
# The help from the trolls can be received either on first sighting of them or
|
||||
# later; so here's what the trolls do to help you wrapped inside a macro so that
|
||||
# the WML doesn't need to be duplicated by hand
|
||||
# The help from the trolls can be received either on first sighting of
|
||||
# them or later; so here's what the trolls do to help you, moved into a
|
||||
# separate event so that the WML doesn't need to be duplicated.
|
||||
|
||||
#define TROLL_HELP
|
||||
[gold]
|
||||
side=1
|
||||
amount=-$troll_help_cost
|
||||
[/gold]
|
||||
[event]
|
||||
name=troll help
|
||||
|
||||
[remove_shroud]
|
||||
side=1
|
||||
x,y=1-38,1-35
|
||||
[/remove_shroud]
|
||||
[gold]
|
||||
side=1
|
||||
amount=-$troll_help_cost
|
||||
[/gold]
|
||||
|
||||
[store_gold]
|
||||
side=4
|
||||
variable=side_4_gold
|
||||
[/store_gold]
|
||||
[remove_shroud]
|
||||
side=1
|
||||
x,y=1-38,1-35
|
||||
[/remove_shroud]
|
||||
|
||||
[modify_side]
|
||||
side=5
|
||||
gold=$side_4_gold
|
||||
hidden=no
|
||||
[/modify_side]
|
||||
[modify_side]
|
||||
side=4
|
||||
hidden=yes
|
||||
[/modify_side]
|
||||
[store_gold]
|
||||
side=4
|
||||
variable=side_4_gold
|
||||
[/store_gold]
|
||||
|
||||
# Note: the order of storing the villages, flipping the
|
||||
# units and recapturing the villages is important, because a
|
||||
# side with no leader cannot own villages.
|
||||
|
||||
[store_villages]
|
||||
owner_side=4
|
||||
variable=side_4_villages
|
||||
[/store_villages]
|
||||
|
||||
{MODIFY_UNIT side=4 side 5}
|
||||
|
||||
[foreach]
|
||||
array=side_4_villages
|
||||
[do]
|
||||
[capture_village]
|
||||
x,y=$this_item.x,$this_item.y
|
||||
[modify_side]
|
||||
side=5
|
||||
[/capture_village]
|
||||
[/do]
|
||||
[/foreach]
|
||||
gold=$side_4_gold
|
||||
hidden=no
|
||||
[/modify_side]
|
||||
[modify_side]
|
||||
side=4
|
||||
hidden=yes
|
||||
[/modify_side]
|
||||
|
||||
{CLEAR_VARIABLE side_4_gold,side_4_villages}
|
||||
# Note: the order of storing the villages, flipping the
|
||||
# units and recapturing the villages is important, because a
|
||||
# side with no leader cannot own villages.
|
||||
|
||||
[message]
|
||||
speaker=Grek
|
||||
message= _ "Gold is good. We can trade gold for weapons and fire. We will help you defeat the undead now."
|
||||
[/message]
|
||||
[message]
|
||||
speaker=Deoran
|
||||
message= _ "What aid can you offer us? We are not well suited to fighting in the caves."
|
||||
[/message]
|
||||
[message]
|
||||
speaker=Grek
|
||||
message= _ "We already planned to kill the undead ourselves... First we kill dwarves though! Now we have dwarvish thunder fire and many trolls ready for fighting. They come too and help you smash them undead."
|
||||
[/message]
|
||||
[lift_fog]
|
||||
[filter_side]
|
||||
side=1
|
||||
[/filter_side]
|
||||
x=16,16,17,17
|
||||
y=23,24,24,25
|
||||
radius=1
|
||||
[/lift_fog]
|
||||
{HIGHLIGHT_IMAGE 17 24 items/bomb.png ()}
|
||||
[message]
|
||||
speaker=Grek
|
||||
scroll=no
|
||||
message= _ "Go here and light the thunder fire and it will blast a back door into the lich’s lair!"
|
||||
[/message]
|
||||
[store_villages]
|
||||
owner_side=4
|
||||
variable=side_4_villages
|
||||
[/store_villages]
|
||||
|
||||
{VARIABLE bomb_ready yes}
|
||||
{VARIABLE troll_allies yes}
|
||||
{CLEAR_VARIABLE late_payment_for_troll_help}
|
||||
#enddef
|
||||
{MODIFY_UNIT side=4 side 5}
|
||||
|
||||
[foreach]
|
||||
array=side_4_villages
|
||||
[do]
|
||||
[capture_village]
|
||||
x,y=$this_item.x,$this_item.y
|
||||
side=5
|
||||
[/capture_village]
|
||||
[/do]
|
||||
[/foreach]
|
||||
|
||||
{CLEAR_VARIABLE side_4_gold,side_4_villages}
|
||||
|
||||
[message]
|
||||
speaker=Grek
|
||||
message= _ "Gold is good. We can trade gold for weapons and fire. We will help you defeat the undead now."
|
||||
[/message]
|
||||
[message]
|
||||
speaker=Deoran
|
||||
message= _ "What aid can you offer us? We are not well suited to fighting in the caves."
|
||||
[/message]
|
||||
[message]
|
||||
speaker=Grek
|
||||
message= _ "We already planned to kill the undead ourselves... First we kill dwarves though! Now we have dwarvish thunder fire and many trolls ready for fighting. They come too and help you smash them undead."
|
||||
[/message]
|
||||
[lift_fog]
|
||||
[filter_side]
|
||||
side=1
|
||||
[/filter_side]
|
||||
x=16,16,17,17
|
||||
y=23,24,24,25
|
||||
radius=1
|
||||
[/lift_fog]
|
||||
{HIGHLIGHT_IMAGE 17 24 items/bomb.png ()}
|
||||
[message]
|
||||
speaker=Grek
|
||||
scroll=no
|
||||
message= _ "Go here and light the thunder fire and it will blast a back door into the lich’s lair!"
|
||||
[/message]
|
||||
|
||||
{VARIABLE bomb_ready yes}
|
||||
{VARIABLE troll_allies yes}
|
||||
{CLEAR_VARIABLE late_payment_for_troll_help}
|
||||
[/event]
|
||||
|
||||
[message]
|
||||
speaker=Deoran
|
||||
|
@ -491,7 +493,9 @@
|
|||
[/variable]
|
||||
|
||||
[then]
|
||||
{TROLL_HELP}
|
||||
[fire_event]
|
||||
name=troll help
|
||||
[/fire_event]
|
||||
[/then]
|
||||
|
||||
[else]
|
||||
|
@ -597,7 +601,9 @@
|
|||
label= _ "Here’s $troll_help_cost for your help against the undead."
|
||||
|
||||
[command]
|
||||
{TROLL_HELP}
|
||||
[fire_event]
|
||||
name=troll help
|
||||
[/fire_event]
|
||||
[/command]
|
||||
[/option]
|
||||
|
||||
|
@ -778,5 +784,3 @@
|
|||
[/endlevel]
|
||||
[/event]
|
||||
[/scenario]
|
||||
|
||||
#undef TROLL_HELP
|
||||
|
|
Loading…
Add table
Reference in a new issue