summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMischa Untaga <99098079+MischaU8@users.noreply.github.com>2024-01-17 15:25:27 +0100
committerMischa Untaga <99098079+MischaU8@users.noreply.github.com>2024-01-17 19:55:11 +0100
commit138b55edd8e0d4d4c36313a22ce79f5435adcec4 (patch)
tree4578f339198a48361be83f74b8893d327144134c
parentd4774e63860985a92ed8b2d449864b4647d983f6 (diff)
downloadplantagenet-138b55edd8e0d4d4c36313a22ce79f5435adcec4.tar.gz
Fix set_active_enemy
-rw-r--r--rules.js9
1 files changed, 3 insertions, 6 deletions
diff --git a/rules.js b/rules.js
index eed8d54..4e2c66f 100644
--- a/rules.js
+++ b/rules.js
@@ -709,12 +709,9 @@ function set_active(new_active) {
}
}
-function set_active(new_active) {
- if (game.active !== new_active) {
- clear_undo() // here
- game.active = new_active
- update_aliases()
- }
+function set_active_enemy() {
+ clear_undo()
+ set_active(enemy_player())
}
function enemy_player() {