summaryrefslogtreecommitdiff
path: root/play.js
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2024-10-22 00:02:23 +0200
committerTor Andersson <tor@ccxvii.net>2024-10-22 00:03:23 +0200
commit9161d8dab4ac318caf41f1f63879d59348d91554 (patch)
tree50f17ba820d2814729e8cd18aed510158b060962 /play.js
parentfc71ebf81c6a7c672e0b13e1c274cef3a2e63b81 (diff)
downloadmaria-9161d8dab4ac318caf41f1f63879d59348d91554.tar.gz
victory check
Diffstat (limited to 'play.js')
-rw-r--r--play.js13
1 files changed, 12 insertions, 1 deletions
diff --git a/play.js b/play.js
index d8353a4..e012337 100644
--- a/play.js
+++ b/play.js
@@ -921,7 +921,18 @@ function layout_retro(s, pow) {
}
function layout_victory_pool(pow, max, x, y) {
- let n = 0
+ let n = view.vp[pow]
+ if (pow === P_PRUSSIA) {
+ if (view.flags & F_SILESIA_ANNEXED) ++n
+ }
+ if (pow === P_FRANCE) {
+ if (view.flags & F_ITALY_FRANCE) ++n
+ if (view.flags & F_EMPEROR_FRANCE) ++n
+ }
+ if (pow === P_AUSTRIA) {
+ if (view.flags & F_ITALY_AUSTRIA) ++n
+ if (view.flags & F_EMPEROR_AUSTRIA) ++n
+ }
for (let i = 0; i < view.victory.length; i += 2)
if (view.victory[i+1] === pow)
++n