-
-
Notifications
You must be signed in to change notification settings - Fork 991
/
11_Clash_of_Armies.cfg
1259 lines (1048 loc) · 35.8 KB
/
11_Clash_of_Armies.cfg
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
#textdomain wesnoth-sotbe
[scenario]
id=11_Clash_of_Armies
name= _ "Clash of Armies"
map_data="{campaigns/Son_Of_The_Black_Eye/maps/11_Clash_of_Armies.map}"
turns=24
{DEFAULT_SCHEDULE_SECOND_WATCH}
next_scenario=12_Giving_Some_Back
{SCENARIO_MUSIC "battle.ogg"}
{EXTRA_SCENARIO_MUSIC "the_city_falls.ogg"}
[event]
name=prestart
[objectives]
side=1
[objective]
description= _ "Defend Prestim successfully for four days"
condition=win
show_turn_counter=yes
[/objective]
[objective]
description= _ "Enemies control any villages on the north side of the river when turns run out"
condition=lose
[/objective]
[objective]
description= _ "Death of Kapou’e"
condition=lose
[/objective]
[objective]
description= _ "Death of Grüü"
condition=lose
[/objective]
[gold_carryover]
bonus=no
carryover_percentage=40
[/gold_carryover]
[/objectives]
[/event]
[side]
side=1
id="Kapou'e"
type=Orcish Leader
controller=human
team_name=Kapoue
user_team_name=_ "Kapou’e"
gold=200
{BLACK_FLAG}
[/side]
{STARTING_VILLAGES 1 10}
{STARTING_VILLAGES_AREA 1 5 5 6}
{STARTING_VILLAGES_AREA 1 35 5 6}
[side]
type=Elvish Champion
id=Thelarion
name= _ "Thelarion"
side=2
canrecruit=yes
facing=sw
[ai]
aggression=1.0
grouping=no
village_value=0.0
leader_value=50.0
[/ai]
recruit=Elvish Captain, Elvish Fighter, Elvish Archer, Elvish Marksman, Elvish Druid, Elvish Scout
team_name=villains
user_team_name=_"Villains"
{GOLD 200 200 250}
{FLAG_VARIANT wood-elvish}
[/side]
{STARTING_VILLAGES 2 10}
[side]
type=Dwarvish Steelclad
id=Darstang
name= _ "Darstang"
side=3
canrecruit=yes
[ai]
aggression=1.0
caution=0.0
villages_per_scout=0
grouping=no
village_value=20
[aspect]
id=recruitment_instructions
[facet]
turns=1-2
[value]
[recruit]
type=Gryphon Rider
number=1
importance=1
[/recruit]
[recruit]
importance=0
type=Dwarvish Fighter, Dwarvish Thunderer, Dwarvish Scout, Bandit
[/recruit]
[/value]
[/facet]
[facet]
turns=3-24
[value]
[recruit]
type=Gryphon Rider
#ifdef HARD
number=3
#else
number=2
#endif
total=yes
importance=1
[/recruit]
[recruit]
importance=0
type=Dwarvish Fighter, Dwarvish Thunderer, Dwarvish Scout, Bandit
[/recruit]
[/value]
[/facet]
[/aspect]
[/ai]
recruit=Dwarvish Fighter, Dwarvish Thunderer, Dwarvish Scout, Bandit, Gryphon Rider
user_team_name=_"Villains"
team_name=villains
{GOLD 200 250 300}
{FLAG_VARIANT knalgan}
[/side]
{STARTING_VILLAGES 3 11}
[side]
type=General
id="Earl Lanbec'h"
name= _ "Earl Lanbec’h"
profile=portraits/lanbech.png
side=4
canrecruit=yes
facing=sw
[ai]
aggression=1.0
grouping=no
leader_value=20
village_value=20
[/ai]
recruit=Swordsman, Red Mage, Pikeman, Heavy Infantryman, Fencer, Bowman
team_name=villains
user_team_name=_"Villains"
{GOLD 200 400 600}
{FLAG_VARIANT loyalist}
[/side]
{STARTING_VILLAGES 4 8}
{STARTING_VILLAGES_AREA 4 19 31 6}
[side]
side=5
[ai]
aggression=1.0
caution=0.25
village_value=10
[/ai]
team_name=villains
user_team_name=_"Villains"
no_leader=yes
[/side]
{SOTBE_TRACK {JOURNEY_11_NEW} }
[event]
name=prestart
#define HUMAN_SHIP X Y FACING_VALUE ID_VALUE
{GENERIC_UNIT 4 "Transport Galleon" {X} {Y}}
[+unit]
facing={FACING_VALUE}
upkeep=free
role="docked transport"
[variables]
transport_num={ID_VALUE}
dock_x={X}
dock_y={Y}
[/variables]
# Let's make the transports slightly more durable than usual so they're
# not as easy to destroy...
[modifications]
[object]
[effect]
apply_to=hitpoints
increase_total=20
[/effect]
[/object]
[/modifications]
[/unit]
#enddef
{HUMAN_SHIP 24 16 sw 1}
{HUMAN_SHIP 14 16 se 2}
{HUMAN_SHIP 26 17 sw 3}
{HUMAN_SHIP 12 17 se 4}
[fire_event]
name=start_boarding_next_transport
[/fire_event]
[role]
type=Orcish Warlord,Troll Warrior,Orcish Warrior,Troll,Orcish Grunt
role=cannonfodder
[auto_recall]
x,y=18,11
[/auto_recall]
[/role]
[role]
role=cannonfodder2
type=Orcish Crossbowman,Orcish Slayer,Orcish Archer,Orcish Assassin
[auto_recall]
x,y=20,11
[/auto_recall]
[/role]
{RENAME_IF_DEAD thelarion_dead Thelarion (_"Telamir")}
{RENAME_IF_DEAD darstang_dead Darstang (_"Angthur")}
[/event]
[event]
name=start
[recall]
id=Grüü
[/recall]
[recall]
id=Jetto
[/recall]
[recall]
id=Inarix
[/recall]
[recall]
id=Plonk
[/recall]
[message]
role=cannonfodder
message= _ "So here we are, and they are preparing to assault."
[/message]
[message]
speaker="Grüü"
message= _ "Prestim’s walls are rock-hard, they’ll waste themselves on them."
[/message]
[message]
speaker="Kapou'e"
message= _ "I’m not that sure. Every fortress has its own weakness. Prestim’s walls are strong but long and it is difficult to defend them from many directions at once. This Earl Lanbec’h must know they can’t break through by only fording the river where the bridge previously stood so he must have a better plan than that."
[/message]
[message]
role=cannonfodder
message= _ "We’ve received messengers from the Council, saying that they are gathering tribes into the Great Horde."
[/message]
[message]
speaker="Grüü"
message= _ "Great! When do they arrive?"
[/message]
[message]
role=cannonfodder
message= _ "In four days. I fear it will be too late."
[/message]
[message]
speaker="Kapou'e"
message= _ "Fool! We can hold that long. But we have to have Prestim firmly in control when the shamans arrive with the Great Horde. We can’t let the humans establish a foothold on this side of the river."
[/message]
[message]
role=cannonfodder
message= _ "Why?"
[/message]
[message]
speaker="Kapou'e"
message= _ "Because if we cannot decisively beat these humans, the other tribes won’t think us strong enough to lead them. Each chieftain will try to claim the leadership of the horde for themselves and the humans will be able to break through our defenses."
[/message]
[message]
role=cannonfodder
message= _ "Great."
[/message]
# TODO: Have Lanbec'h say something
[/event]
# If a transport which is in the process of being boarded dies, free the
# would-be-boarders and start boarding the next transport instead. This is
# probably unnecessary as killing a transport which is about to be boarded
# would require the player to reach the boarding areas, but better safe than
# sorry...
[event]
name=die
first_time_only=no
[filter]
type=Transport Galleon
[filter_wml]
[variables]
transport_num=$transport_to_board
[/variables]
[/filter_wml]
[/filter]
{MODIFY_UNIT (
[filter_wml]
[variables]
boarding_transport=yes
[/variables]
[/filter_wml]
[filter_adjacent]
x,y=$x1,$y1
[/filter_adjacent]
) variables.boarding_transport no}
[fire_event]
name=start_boarding_next_transport
[/fire_event]
[/event]
# This event triggers when the current transport to board has three adjacent
# units ready to board it. Then it shows all three units board the
# transport, stores those units in the transport's variables so they can be
# unstored when the transport unloads.
[event]
name=side 4 turn refresh
first_time_only=no
[filter_condition]
[have_unit]
type=Transport Galleon
[filter_wml]
[variables]
transport_num=$transport_to_board
[/variables]
[/filter_wml]
[filter_adjacent]
[filter_wml]
[variables]
boarding_transport=yes
[/variables]
[/filter_wml]
count=3
[/filter_adjacent]
[/have_unit]
[/filter_condition]
{VARIABLE_OP ships_boarded add 1}
[switch]
variable=ships_boarded
[case]
value=1
[message]
speaker=Grüü
message= _ "Look, the humans are boarding a ship!"
[/message]
[/case]
[/switch]
[store_unit]
[filter]
type=Transport Galleon
[filter_wml]
[variables]
transport_num=$transport_to_board
[/variables]
[/filter_wml]
[/filter]
kill=no
variable=transport
[/store_unit]
[store_unit]
[filter]
[filter_wml]
[variables]
boarding_transport=yes
[/variables]
[/filter_wml]
[/filter]
kill=no
variable=transport.variables.landing_party
[/store_unit]
[foreach]
array=transport.variables.landing_party
[do]
[kill]
x=$this_item.x
y=$this_item.y
fire_event=no
[/kill]
[move_unit_fake]
x=$this_item.x,$transport.x
y=$this_item.y,$transport.y
type=$this_item.type
gender=$this_item.gender
side=4
[/move_unit_fake]
{VARIABLE this_item.moves 0}
{VARIABLE this_item.attacks_left 0}
{CLEAR_VARIABLE this_item.variables.boarding_transport}
[/do]
[/foreach]
[unstore_unit]
variable=transport
find_vacant=no
[/unstore_unit]
[fire_event]
name=start_boarding_next_transport
[/fire_event]
{CLEAR_VARIABLE transport}
[/event]
# This makes each transport which has a landing party to move towards a
# randomly selected landing spot.
[event]
name=side 4 turn refresh
first_time_only=no
[store_unit]
[filter]
type=Transport Galleon
[filter_wml]
[variables]
[landing_party]
[/landing_party]
[/variables]
[/filter_wml]
[/filter]
kill=no
variable=moving_transports
[/store_unit]
[foreach]
array=moving_transports
[do]
[if]
[variable]
name=this_item.x
less_than=19
[/variable]
[then]
{VARIABLE x "1-17"}
[/then]
[else]
{VARIABLE x "21-38"}
[/else]
[/if]
[store_locations]
x=$x
y=7-11
terrain=W*
[filter_adjacent_location]
terrain=!,W*
count=2-6
[/filter_adjacent_location]
[not]
[filter]
[/filter]
radius=1
[/not]
variable=landing_sites
[/store_locations]
#{DEBUG_MSG "Found $landing_sites.length possible landing sites for transport $this_item.variables.transport_num"}
[if]
[variable]
name=landing_sites.length
greater_than_equal_to=1
[/variable]
[then]
{RANDOM "0..$($landing_sites.length - 1)"}
{VARIABLE goto_x $landing_sites[$random].x}
{VARIABLE goto_y $landing_sites[$random].y}
{VARIABLE this_item.goto_x $goto_x}
{VARIABLE this_item.goto_y $goto_y}
#{DEBUG_MSG "Setting transport $this_item.variables.transport_num to goto $goto_x|,$goto_y"}
[unstore_unit]
variable=this_item
find_vacant=no
[/unstore_unit]
[/then]
[/if]
[/do]
[/foreach]
{CLEAR_VARIABLE moving_transports,landing_sites,x,goto_x,goto_y,random}
[/event]
# This picks a nearby side 4 unit and flags it as one which should move
# towards the transport. First looks for a unit which is within one turn's
# movement, then for units within one turn's movement + 1 hex, then for
# units within one turn's movement + 2 hex, etc, but doesn't pick units
# which are more than 2 turns away and gives up when +6 is reached.
[event]
name=side 4 turn refresh
first_time_only=no
[filter_condition]
[have_unit]
[filter_wml]
[variables]
boarding_transport=yes
[/variables]
[/filter_wml]
count=0-2
[/have_unit]
[/filter_condition]
{VARIABLE i 0}
[while]
[variable]
name=possible_boarders.length
less_than=1
[/variable]
[variable]
name=i
less_than=6
[/variable]
[do]
[store_unit]
[filter]
side=4
canrecruit=no
[not]
type=Transport Galleon
[/not]
[filter_wml]
hitpoints=$this_unit.max_hitpoints
[/filter_wml]
[not]
[filter_wml]
[variables]
boarding_transport=yes
[/variables]
[/filter_wml]
[/not]
[and]
[filter_location]
[filter]
type=Transport Galleon
[filter_wml]
[variables]
transport_num=$transport_to_board
[/variables]
[/filter_wml]
[/filter]
radius="$($this_unit.moves + min($i,$this_unit.moves))"
[filter_radius]
terrain=G*,R*,C*,K*,*^V*,Wwf
[/filter_radius]
[/filter_location]
[/and]
[/filter]
kill=no
variable=possible_boarders
[/store_unit]
{VARIABLE_OP i add 1}
[/do]
[/while]
[if]
[variable]
name=possible_boarders.length
greater_than_equal_to=1
[/variable]
[then]
{RANDOM "0..$($possible_boarders.length - 1)"}
{VARIABLE possible_boarders[$random].variables.boarding_transport yes}
#{DEBUG_MSG "Setting $possible_boarders[$random].name the $possible_boarders[$random].language_name to board transport $transport_to_board"}
[unstore_unit]
variable=possible_boarders[$random]
find_vacant=no
[/unstore_unit]
[/then]
#[else]
# {DEBUG_MSG "Found no one to go to board transport $transport_to_board|..."}
#[/else]
[/if]
{CLEAR_VARIABLE possible_boarders,random}
[/event]
# This makes units which have been designated to board a transport to move
# towards the current transport to board.
[event]
name=side 4 turn refresh
first_time_only=no
[store_unit]
[filter]
side=4
[filter_wml]
[variables]
boarding_transport=yes
[/variables]
[/filter_wml]
[not]
[filter_adjacent]
[filter_wml]
[variables]
transport_num=$transport_to_board
[/variables]
[/filter_wml]
[/filter_adjacent]
[/not]
[/filter]
kill=no
variable=moving_to_transport
[/store_unit]
[foreach]
array=moving_to_transport
[do]
# First we try to find a proper boarding location which the unit can
# reach in one turn...
[store_locations]
terrain=!,W*
[filter_adjacent_location]
[filter]
[filter_wml]
[variables]
transport_num=$transport_to_board
[/variables]
[/filter_wml]
[/filter]
[/filter_adjacent_location]
[not]
[filter]
[/filter]
[/not]
[and]
[filter]
x,y=$this_item.x,$this_item.y
[/filter]
radius=$this_item.moves
[filter_radius]
terrain=G*,R*,C*,K*,*^V*,Wwf
[/filter_radius]
[/and]
variable=boarding_locs
[/store_locations]
# ...but if no such location was found, then we just make the unit
# head for the transport itself for now.
[if]
[variable]
name=boarding_locs.length
less_than=1
[/variable]
[then]
[store_locations]
[filter]
[filter_wml]
[variables]
transport_num=$transport_to_board
[/variables]
[/filter_wml]
[/filter]
variable=boarding_locs
[/store_locations]
[/then]
[/if]
{RANDOM "0..$($boarding_locs.length - 1)"}
{VARIABLE this_item.goto_x $boarding_locs[$random].x}
{VARIABLE this_item.goto_y $boarding_locs[$random].y}
#{DEBUG_MSG "Setting $this_item.name the $this_item.language_name to go to $boarding_locs[$random].x|,$boarding_locs[$random].y"}
[unstore_unit]
variable=this_item
find_vacant=no
[/unstore_unit]
[/do]
[/foreach]
{CLEAR_VARIABLE moving_to_transport,boarding_locs,random}
[/event]
[event]
name=side 4 turn refresh
first_time_only=no
# Zero the movement of docked transports
{MODIFY_UNIT (
type=Transport Galleon
x,y=$this_unit.variables.dock_x,$this_unit.variables.dock_y
[not]
[filter_wml]
[variables]
[landing_party]
[/landing_party]
[/variables]
[/filter_wml]
[/not]
) moves 0}
# Zero the movement of units waiting to board a transport
{MODIFY_UNIT (
side=4
[filter_wml]
[variables]
boarding_transport=yes
[/variables]
[/filter_wml]
[filter_adjacent]
[filter_wml]
[variables]
transport_num=$transport_to_board
[/variables]
[/filter_wml]
[/filter_adjacent]
) moves 0}
[/event]
# When a transport reaches the northern shore in a spot which has at least 3
# adjacent free non-deep hexes, so that there's enough space to unload the
# whole landing party.
[event]
name=moveto
first_time_only=no
[filter]
type=Transport Galleon
[filter_location]
x=1-38
y=7-11
[filter_adjacent_location]
[not]
[filter]
[/filter]
[/not]
terrain=!,W*
count=1-6
[/filter_adjacent_location]
[and]
[filter_adjacent_location]
[not]
[filter]
[/filter]
[/not]
terrain=!,Wo
count=3-6
[/filter_adjacent_location]
[/and]
[/filter_location]
[/filter]
[foreach]
array=unit.variables.landing_party
[do]
[store_locations]
terrain=!,W*
[filter_adjacent_location]
x,y=$x1,$y1
[/filter_adjacent_location]
[not]
[filter]
[/filter]
[/not]
variable=disembark_loc
[/store_locations]
[if]
[variable]
name=disembark_loc.length
less_than=1
[/variable]
[then]
[store_locations]
terrain=!,Wo
[filter_adjacent_location]
x,y=$x1,$y1
[/filter_adjacent_location]
[not]
[filter]
[/filter]
[/not]
variable=disembark_loc
[/store_locations]
[/then]
[/if]
[move_unit_fake]
x=$unit.x,$disembark_loc.x
y=$unit.y,$disembark_loc.y
type=$this_item.type
gender=$this_item.gender
side=4
[/move_unit_fake]
[unstore_unit]
variable=this_item
x,y=$disembark_loc.x,$disembark_loc.y
[/unstore_unit]
[/do]
[/foreach]
{VARIABLE_OP landing_parties_landed add 1}
[switch]
variable=landing_parties_landed
[case]
value=1
[message]
x,y=$disembark_loc.x,$disembark_loc.y
message= _ "Charge!"
[/message]
[/case]
[case]
value=2
[message]
x,y=$disembark_loc.x,$disembark_loc.y
message= _ "Get them!"
[/message]
[/case]
[/switch]
{CLEAR_VARIABLE unit.variables.landing_party,disembark_loc}
{VARIABLE unit.moves 0}
[unstore_unit]
variable=unit
find_vacant=no
[/unstore_unit]
[/event]
# This makes transports which have no landing party and aren't at their dock
# location to return to their dock. This should only be the case when a
# transport has unloaded their landing party but hasn't yet returned.
[event]
name=side 4 turn refresh
first_time_only=no
[store_unit]
[filter]
type=Transport Galleon
[not]
x,y=$this_unit.variables.dock_x,$this_unit.variables.dock_y
[/not]
[not]
[filter_wml]
[variables]
[landing_party]
[/landing_party]
[/variables]
[/filter_wml]
[/not]
[/filter]
kill=yes
variable=returning_transports
[/store_unit]
[foreach]
array=returning_transports
[do]
{VARIABLE this_item.goto_x $this_item.variables.dock_x}
{VARIABLE this_item.goto_y $this_item.variables.dock_y}
#{DEBUG_MSG "Setting transport $this_item.variables.transport_num to return to $this_item.variables.dock_x|,$this_item.variables.dock_y"}
[unstore_unit]
variable=this_item
[/unstore_unit]
[/do]
[/foreach]
{CLEAR_VARIABLE returning_transports}
[/event]
# This event simply cycles the variable $transport_to_board through values
# of 1,2,3,4,1,2,3,4,1,2,..., starting from whatever value it is originally
# set to (if not, then the first call to this sets it to 1).
[event]
name=start_boarding_next_transport
first_time_only=no
{VARIABLE i $transport_to_board}
[if]
[variable]
name=i
less_than=4
[/variable]
[then]
{VARIABLE_OP i add 1}
[/then]
[else]
{VARIABLE i 1}
[/else]
[/if]
[while]
[not]
[have_unit]
type=Transport Galleon
[filter_wml]
[variables]
transport_num=$i