Got rid of commas in variable names...
...and prevented the guards from having identical ids.
This commit is contained in:
parent
4d1c2b3936
commit
ec3c2ea8cc
1 changed files with 5 additions and 6 deletions
|
@ -106,7 +106,7 @@
|
|||
[/event]
|
||||
|
||||
# Generate a random number of guards between 0 and 2 around X,Y
|
||||
#define RANDOM_GUARDS TYPE ID_STRING NAME_STRING SIDE X Y
|
||||
#define RANDOM_GUARDS TYPE NAME_STRING SIDE X Y
|
||||
{VARIABLE_OP number_of_guards random 0..2}
|
||||
|
||||
{REPEAT $number_of_guards (
|
||||
|
@ -135,7 +135,6 @@
|
|||
[/move_unit_fake]
|
||||
|
||||
[unit]
|
||||
id={ID_STRING}
|
||||
name={NAME_STRING} # wmllint: ignore
|
||||
type={TYPE}
|
||||
side={SIDE}
|
||||
|
@ -168,11 +167,11 @@
|
|||
side=1
|
||||
[/filter]
|
||||
|
||||
{IF_VAR village_$x1,$y1|_cleared not_equals yes (
|
||||
{IF_VAR village_$x1|_$y1|_cleared not_equals yes (
|
||||
[then]
|
||||
{RANDOM_GUARDS (Goblin Spearman) Villager (_ "Villager") 2 $x1 $y1}
|
||||
{RANDOM_GUARDS (Goblin Spearman) (_ "Villager") 2 $x1 $y1}
|
||||
|
||||
{VARIABLE village_$x1,$y1|_cleared yes}
|
||||
{VARIABLE village_$x1|_,$y1|_cleared yes}
|
||||
[/then]
|
||||
|
||||
[else]
|
||||
|
@ -259,7 +258,7 @@
|
|||
[/store_villages]
|
||||
|
||||
{FOREACH villages i}
|
||||
{VARIABLE_OP village_var format "village_$villages[$i].x,$villages[$i].y|_cleared"}
|
||||
{VARIABLE_OP village_var format "village_$villages[$i].x|_$villages[$i].y|_cleared"}
|
||||
|
||||
{CLEAR_VARIABLE $village_var}
|
||||
{NEXT i}
|
||||
|
|
Loading…
Add table
Reference in a new issue