summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--rules.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/rules.js b/rules.js
index a7b7fde..36605e5 100644
--- a/rules.js
+++ b/rules.js
@@ -7916,12 +7916,12 @@ states.vm_place_or_remove_insurgent_base = {
},
piece(p) {
push_undo()
- if (piece_space(p) === AVAILABLE) {
- log("Placed " + piece_name(p) + " in S" + game.vm.s + ".")
- place_piece(p, game.vm.s)
- } else {
+ if (piece_space(p) === game.vm.s) {
log("Removed " + piece_name(p) + " from S" + game.vm.s + ".")
remove_piece(p)
+ } else {
+ log("Placed " + piece_name(p) + " in S" + game.vm.s + ".")
+ place_piece(p, game.vm.s)
}
vm_next()
},