2022-08-19 17:19:08 +00:00
|
|
|
function st_enemyturn() {
|
|
|
|
while global.turn == ARMY.THEM {
|
|
|
|
var done = true;
|
|
|
|
for (k=0; k<array_length(global.units[ARMY.THEM]); k++) {
|
|
|
|
var target = global.units[ARMY.THEM][k];
|
|
|
|
if !target.waiting {
|
|
|
|
done = false;
|
|
|
|
} else {
|
|
|
|
continue;
|
|
|
|
}
|
|
|
|
c_doenemyai(target);
|
|
|
|
}
|
|
|
|
if done {
|
|
|
|
c_dewait(global.turn);
|
|
|
|
state = st_control;
|
2022-08-23 01:28:48 +00:00
|
|
|
global.turn = ARMY.US;
|
2022-08-19 17:19:08 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|