-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathoptions.cfg
859 lines (809 loc) · 25.3 KB
/
options.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
#textdomain wesnoth-Eastern_Europe_at_War
#This file contains a set of different modifications of the EEaW gameplay
#---------------------------------------------------------------
#Abilities
#---------------------------------------------------------------
#define OPTION_CASTLESDESTRUCTION
[checkbox]
id=eeawcastlesdestruction
default=yes
name=_"Destruction of castles"
description=_ "Enables Swedish culverins to destroy fortifications of all kinds."
[/checkbox]
# wmlxgettext: [options]
[/options]
[event]
name=recruit
first_time_only=no
[filter]
has_weapon=siege
[/filter]
[if]
{VARIABLE_CONDITIONAL eeawcastlesdestruction equals no}
[then]
[modify_unit]
[filter]
id=$unit.id
[/filter]
[object]
[filter]
id=$unit.id
[/filter]
[effect]
apply_to=attack
remove_specials=eeaw_keepkiller
[/effect]
[/object]
[/modify_unit]
[/then]
[/if]
[/event]
[+options]
#enddef
#define OPTION_ECONOMY
[checkbox]
id=eeaweconomy
default=yes
name=_"Economy"
description=_ "Enables certain units to generate additional income."
[/checkbox]
[/options]
[event]
name=recruit
first_time_only=no
[filter]
ability=eeaw_slavemarket
[/filter]
[if]
{VARIABLE_CONDITIONAL eeaweconomy equals no}
[then]
[modify_unit]
[filter]
id=$unit.id
[/filter]
[object]
[filter]
id=$unit.id
[/filter]
[effect]
apply_to=remove_ability
[abilities]
{ABILITY_SLAVEMARKET}
[/abilities]
[/effect]
[/object]
[/modify_unit]
[modify_unit]
[filter]
id=$unit.id
[/filter]
[object]
[filter]
id=$unit.id
[/filter]
[effect]
apply_to=remove_ability
[abilities]
{ABILITY_EEAWCAPTURE}
[/abilities]
[/effect]
[/object]
[/modify_unit]
[/then]
[/if]
[/event]
[+options]
#enddef
#---------------------------------------------------------------
#Units
#---------------------------------------------------------------
#define OPTION_HOSPITALS
[checkbox]
id=eeawhospitals
default=yes
name=_"Field Hospitals"
description=_ "Enables recruitment of Field Hospitals."
[/checkbox]
[/options]
[event]
name=side turn 1
first_time_only=no
[if]
{VARIABLE_CONDITIONAL eeawhospitals equals no}
[then]
[disallow_recruit]
side=$side_number
type=zSzField Hospital,z_sField Hospital
[/disallow_recruit]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Poles}
[then]
{VARIABLE_OP player_$side_number|_recruitscount sub 1}
[/then]
[/if]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Swedes}
[then]
{VARIABLE_OP player_$side_number|_recruitscount sub 1}
[/then]
[/if]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Turks}
[then]
{VARIABLE_OP player_$side_number|_recruitscount sub 1}
[/then]
[/if]
[/then]
[/if]
[/event]
[+options]
#enddef
#define OPTION_SHIPS
[checkbox]
id=eeawships
default=yes
name=_"Ships"
description=_ "Enables recruitment of ships."
[/checkbox]
[/options]
[event]
name=side turn 1
first_time_only=no
[if]
{VARIABLE_CONDITIONAL eeawships equals no}
[then]
[disallow_recruit]
side=$side_number
type=ta Ferryboat I,ta Ferryboat I2,ta Tatar Boat,zz Ship I,zz Ship II,zz Ship III,sz Light Galleon,sz Line Ship,sz Galleon,sz Battleship,tu Fusta,tu Galiot,tu Galley,tu Bomba Gemisi,kz Chaika,kz Great Chaika
[/disallow_recruit]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Poles}
[then]
{VARIABLE_OP player_$side_number|_recruitscount sub 1}
[/then]
[/if]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Tatars}
[then]
{VARIABLE_OP player_$side_number|_recruitscount sub 2}
[/then]
[/if]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Cossacks}
[then]
{VARIABLE_OP player_$side_number|_recruitscount sub 1}
[/then]
[/if]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Russians}
[then]
{VARIABLE_OP player_$side_number|_recruitscount sub 1}
[/then]
[/if]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Turks}
[then]
{VARIABLE_OP player_$side_number|_recruitscount sub 2}
[/then]
[/if]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Swedes}
[then]
{VARIABLE_OP player_$side_number|_recruitscount sub 2}
[/then]
[/if]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Austrians}
[then]
{VARIABLE_OP player_$side_number|_recruitscount sub 1}
[/then]
[/if]
[/then]
[/if]
[/event]
[+options]
#enddef
#define OPTION_FULLFLEET
[checkbox]
id=eeawfullfleet
default=no
name=_"Full fleet recruitment"
description=_ "Enables players to recruit all levels of their ships, not only level 1. Remember to enable ships first."
[/checkbox]
[/options]
[event]
name=side turn 1
first_time_only=no
[if]
{VARIABLE_CONDITIONAL eeawships equals yes}
[and]
{VARIABLE_CONDITIONAL eeawfullfleet equals yes}
[/and]
[then]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Poles}
[or]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Austrians}
[/or]
[or]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Russians}
[/or]
[then]
[allow_recruit]
side=$side_number
type=zz Ship II,zz Ship III
[/allow_recruit]
[/then]
[/if]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Tatars}
[then]
[allow_recruit]
side=$side_number
type=ta Ferryboat I2
[/allow_recruit]
[/then]
[/if]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Swedes}
[then]
[allow_recruit]
side=$side_number
type=sz Galleon,sz Battleship, sz Regalskeppet
[/allow_recruit]
[/then]
[/if]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Turks}
[then]
[allow_recruit]
side=$side_number
type=tu Galiot,tu Galley
[/allow_recruit]
[/then]
[/if]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Cossacks}
[then]
[allow_recruit]
side=$side_number
type=kz Great Chaika
[/allow_recruit]
[/then]
[/if]
[/then]
[/if]
[/event]
[+options]
#enddef
#define OPTION_PEASANTS
[checkbox]
id=eeawpeasants
default=yes
name=_"Level 0 units"
description=_ "Enables recruitment of level 0 units. (Not recommended for MP)"
[/checkbox]
[/options]
[event]
name=side turn 1
first_time_only=no
[if]
{VARIABLE_CONDITIONAL eeawpeasants equals no}
[then]
[disallow_recruit]
side=$side_number
type=kz Ukrainian Peasant,pl Polish Peasant,ru Russian Peasant,sz Swedish Peasant,tu Slave,tu Mehterane
[/disallow_recruit]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Poles}
[then]
{VARIABLE_OP player_$side_number|_recruitscount sub 1}
[/then]
[/if]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Swedes}
[then]
{VARIABLE_OP player_$side_number|_recruitscount sub 1}
[/then]
[/if]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Turks}
[then]
{VARIABLE_OP player_$side_number|_recruitscount sub 1}
[/then]
[/if]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Russians}
[then]
{VARIABLE_OP player_$side_number|_recruitscount sub 1}
[/then]
[/if]
[if]
{VARIABLE_CONDITIONAL player_$side_number|_faction equals Cossacks}
[then]
{VARIABLE_OP player_$side_number|_recruitscount sub 1}
[/then]
[/if]
[/then]
[/if]
[/event]
[+options]
#enddef
#---------------------------------------------------------------
#RULES
#---------------------------------------------------------------
#define LASTMAN_ACTION LEVEL
#locate free keeps
{VARIABLE distance 0}
[while]
[not]
[have_location]
terrain=K*
[and]
[filter]
side=$unit.side
level={LEVEL}
[not]
id=$unit.id
[/not]
[/filter]
radius=$distance
[/and]
[not]
[filter]
[/filter]
[/not]
[/have_location]
[/not]
[not]
[variable]
name=distance
greater_than_equal_to=99
[/variable]
[/not]
[do]
{VARIABLE_OP distance add 1}
[/do]
[/while]
{IF_VAR distance greater_than_equal_to 99 (
[then]
#mark random unit as leader
[store_unit]
[filter]
side=$unit.side
level={LEVEL}
[not]
canrecruit=yes
[/not]
[/filter]
variable=newleader
[/store_unit]
{VARIABLE newleader[0].canrecruit yes}
{VARIABLE newleader[0].upkeep loyal}
[unstore_unit]
variable=newleader[0]
find_vacant=no
[/unstore_unit]
[/then]
[else]
#mark as new leader
[store_unit]
[filter]
side=$unit.side
level={LEVEL}
[filter_location]
terrain=K*
radius=$distance
[/filter_location]
[not]
canrecruit=yes
[/not]
[/filter]
variable=newleader
[/store_unit]
{VARIABLE newleader[0].canrecruit yes}
{VARIABLE newleader[0].upkeep loyal}
[unstore_unit]
variable=newleader[0]
find_vacant=no
[/unstore_unit]
[/else]
)}
{CLEAR_VARIABLE newleader}
#enddef
#define OPTION_LASTMANSTANDING
[checkbox]
id=eeawlastman
default=no
name=_"WIN CONDITION: Last man standing"
description=_ "The player who eliminates ALL enemy units wins. This overrides default Kill Enemy Leader rule."
[/checkbox]
[/options]
[event]
name=last breath
first_time_only=no
[filter]
canrecruit=yes
[/filter]
[if]
{VARIABLE_CONDITIONAL eeawlastman equals yes}
[then]
[if]
#has any units?
[have_unit]
side=$unit.side
count=1-9999
[/have_unit]
[then]
#find new leader - highest level available
[if]
#has 4lvl units?
[have_unit]
side=$unit.side
level=4
[/have_unit]
[then]
{LASTMAN_ACTION 4}
[/then]
[else]
[if]
#has 3lvl units?
[have_unit]
side=$unit.side
level=3
[/have_unit]
[then]
{LASTMAN_ACTION 3}
[/then]
[else]
[if]
#has 2lvl units?
[have_unit]
side=$unit.side
level=2
[/have_unit]
[then]
{LASTMAN_ACTION 2}
[/then]
[else]
[if]
#has 1lvl units?
[have_unit]
side=$unit.side
level=1
[/have_unit]
[then]
{LASTMAN_ACTION 1}
[/then]
[else]
{LASTMAN_ACTION 0}
[/else]
[/if]
[/else]
[/if]
[/else]
[/if]
[/else]
[/if]
[/then]
[/if]
[/then]
[/if]
[/event]
[+options]
#enddef
#---------------------------------------------------------------
#GAME MODES
#---------------------------------------------------------------
#define OPTION_DEADLINE
[slider]
id=eeawdeadline
default=0
min=0
max=25
name=_"Recruitment Deadline"
description=_ "You can recruit units for a limited number of turns. Then all recruitment is disabled. Setting the slider to 0 turns off this feature."
[/slider]
[/options]
[event]
name=side turn
first_time_only=no
[if]
{VARIABLE_CONDITIONAL eeawdeadline not_equals 0}
[then]
[if]
{VARIABLE_CONDITIONAL turn_number equals $eeawdeadline}
[then]
[print]
text=_"RECRUITMENT DISABLED!"
duration=400
size=18
{COLOR_HARM}
[/print]
[disallow_recruit]
side=$side_number
type=$player_$side_number|_list
[/disallow_recruit]
[/then]
[else]
[if]
{VARIABLE_CONDITIONAL turn_number less_than $eeawdeadline}
[then]
{VARIABLE deadline $eeawdeadline}
{VARIABLE_OP deadline sub $turn_number}
[print]
text=_"Recruitment ends in "+$deadline+" turn(s)"
duration=300
size=18
{COLOR_HARM}
[/print]
{CLEAR_VARIABLE deadline}
[/then]
[/if]
[/else]
[/if]
[/then]
[/if]
[/event]
[+options]
#enddef
#define OPTION_LIMITRECRUITS
[slider]
id=eeawlimitrecruits
default=0
min=0
max=50
name=_"Limited Recruits"
description=_ "You can recruit only a limited number of units. After reaching the specified limit, you can no longer recruit. Setting the slider to 0 turns off this feature."
[/slider]
[/options]
[event]
name=recruit
first_time_only=no
[if]
{VARIABLE_CONDITIONAL eeawlimitrecruits not_equals 0}
[then]
[if]
[have_unit]
side=$side_number
[not]
canrecruit=yes
[/not]
count=$eeawlimitrecruits
[/have_unit]
[then]
[disallow_recruit]
side=$side_number
type=$player_$side_number|_list
[/disallow_recruit]
[unstore_unit]
variable=unit
find_vacant=no
text=_"Limit reached!"
{COLOR_HARM}
[/unstore_unit]
[/then]
[else]
[store_unit]
[filter]
side=$side_number
[not]
canrecruit=yes
[/not]
[/filter]
variable=recruits
[/store_unit]
[if]
{VARIABLE_CONDITIONAL eeawlimitrecruits greater_than $recruits.length}
[then]
{VARIABLE recruitsleft $eeawlimitrecruits}
{VARIABLE_OP recruitsleft sub $recruits.length}
[unstore_unit]
variable=unit
find_vacant=no
text=_"$recruitsleft recruits left"
{COLOR_HARM}
[/unstore_unit]
{CLEAR_VARIABLE recruitsleft}
[/then]
[/if]
{CLEAR_VARIABLE recruits}
[/else]
[/if]
[/then]
[/if]
[/event]
[+options]
#enddef
#define OPTION_BOSSMODE
[slider]
id=eeawbossmode
default=0
min=0
max=100
step=10
name=_"Boss mode - leader's bonus hp:"
description=_ "All faction leaders receive bonus hp."
[/slider]
[/options]
[event]
name=turn 1
first_time_only=no
[if]
{VARIABLE_CONDITIONAL eeawbossmode not_equals 0}
[then]
[store_unit]
[filter]
canrecruit=yes
[/filter]
variable=leaders
[/store_unit]
[foreach]
array=leaders
[do]
{VARIABLE_OP this_item.max_hitpoints add $eeawbossmode}
{VARIABLE_OP this_item.hitpoints add $eeawbossmode}
[unstore_unit]
variable=this_item
find_vacant=no
[/unstore_unit]
[/do]
[/foreach]
{CLEAR_VARIABLE leaders}
[/then]
[/if]
[/event]
[event]
name=post advance
first_time_only=no
[filter]
canrecruit=yes
[/filter]
[if]
{VARIABLE_CONDITIONAL eeawbossmode not_equals 0}
[then]
{VARIABLE_OP unit.max_hitpoints add $eeawbossmode}
{VARIABLE_OP unit.hitpoints add $eeawbossmode}
[unstore_unit]
variable=unit
find_vacant=no
[/unstore_unit]
[/then]
[/if]
[/event]
[+options]
#enddef
#define OPTION_PILLAGER
[slider]
id=eeawpillager
default=0
min=0
max=30
step=5
name=_"Pillager Mode"
description=_ "Every time you capture a neutral or enemy village, you receive bonus gold. Works great with No Income mode."
[/slider]
[/options]
[event]
name=capture
first_time_only=no
[filter]
[/filter]
[if]
{VARIABLE_CONDITIONAL eeawpillager not_equals 0}
[then]
[store_side]
side=$unit.side
variable=sidecheck1
[/store_side]
[store_side]
side=$owner_side
variable=sidecheck2
[/store_side]
{IF_VAR sidecheck1.user_team_name equals $sidecheck2.user_team_name (
[else]
[gold]
amount=$eeawpillager
side=$unit.side
[/gold]
[sound]
name=gold.ogg
[/sound]
[unstore_unit]
variable=unit
text=$eeawpillager
red,green,blue=255,255,0
find_vacant=no
[/unstore_unit]
[/else]
)}
{CLEAR_VARIABLE sidecheck1}
{CLEAR_VARIABLE sidecheck2}
[/then]
[/if]
[/event]
[+options]
#enddef
#define OPTION_NOINCOME
[checkbox]
id=eeawnoincome
default=no
name=_"No Income"
description=_ "Disables all sources of income. All units have no upkeep costs. Turns off all economy related abilities."
[/checkbox]
[/options]
#disable economy
[event]
name=start
{VARIABLE eeaweconomy no}
[/event]
[event]
name=turn 1
first_time_only=no
[if]
{VARIABLE_CONDITIONAL eeawnoincome equals yes}
[then]
[modify_side]
[filter_side]
side="1-9"
[/filter_side]
income=-2
village_gold=0
[/modify_side]
[/then]
[/if]
[/event]
[event]
name=recruit
first_time_only=no
[if]
{VARIABLE_CONDITIONAL eeawnoincome equals yes}
[then]
{MODIFY_UNIT find_in=unit upkeep loyal}
[/then]
[/if]
[/event]
[+options]
#enddef
#define OPTION_NOSPAM
[checkbox]
id=eeawnospam
default=no
name=_"No Spam"
description=_ "You can only recruit each unit once. When you run out of possible recruits, the cycle is reset."
[/checkbox]
[/options]
[event]
name=recruit
first_time_only=no
[if]
{VARIABLE_CONDITIONAL eeawnospam equals yes}
[then]
[store_side]
variable=side_check
side=$side_number
[/store_side]
{VARIABLE_OP player_$side_number|_counter add 1}
[if]
{VARIABLE_CONDITIONAL player_$side_number|_counter less_than $player_$side_number|_recruitscount}
[then]
[disallow_recruit]
side=$side_number
type=$unit.type
[/disallow_recruit]
[/then]
[else]
{VARIABLE player_$side_number|_counter 0}
{VARIABLE copyvar1 $player_$side_number|_list}
[set_recruit]
side=$side_number
recruit=$copyvar1
[/set_recruit]
[/else]
[/if]
[/then]
[/if]
[/event]
[+options]
# wmlxgettext: [/options]
#enddef