diff options
author | Tor Andersson <tor@ccxvii.net> | 2024-10-21 11:45:33 +0200 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2024-10-21 11:51:54 +0200 |
commit | d47d48c2d24f65ee8c753f175dcbb3e0b4ed18ec (patch) | |
tree | 1731d9496ef2bf20deb4cd43480f22551004df30 /play.js | |
parent | 5b20a8ae9194fe76c6b589005687a6e33682e1ef (diff) | |
download | maria-d47d48c2d24f65ee8c753f175dcbb3e0b4ed18ec.tar.gz |
winter recruitment
Diffstat (limited to 'play.js')
-rw-r--r-- | play.js | 11 |
1 files changed, 10 insertions, 1 deletions
@@ -84,6 +84,15 @@ const piece_power = [ P_AUSTRIA, P_AUSTRIA ] +const piece_rank = [ + 1, 2, 3, 4, 5, + 1, + 1, 2, 3, 4, + 1, + 1, 2, 3, + 1, 2, 3, 4, 5, 6, +] + const piece_abbr = [ "F1", "F2", "F3", "F4", "F5", "B1", @@ -688,7 +697,7 @@ function layout_general_offset(who, here) { return 1 if ((view.supreme & (1 << other)) || view.selected === other) return 0 - if (who < other) + if (piece_rank[who] < piece_rank[other]) return 1 return 0 } |