summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2023-11-01 16:06:14 +0100
committerTor Andersson <tor@ccxvii.net>2023-11-02 01:17:35 +0100
commitbbf92d39cc744ca0cbcd2ad54b19d4b2db0e06e3 (patch)
tree2600cea2829eb2d96e582bfeeaa79aad0c8c40ff
parent45d6e8af6ea16ddc813fc86f93af600ac3d9f870 (diff)
downloadalgeria-bbf92d39cc744ca0cbcd2ad54b19d4b2db0e06e3.tar.gz
Shorter names.
-rw-r--r--data.js2
-rw-r--r--play.js10
-rw-r--r--rules.js74
-rw-r--r--tools/gendata.js27
4 files changed, 65 insertions, 48 deletions
diff --git a/data.js b/data.js
index d49a521..4e5ca32 100644
--- a/data.js
+++ b/data.js
@@ -1,2 +1,2 @@
-const data = {"locations":{"NONE":0,"DEPLOY":1,"ELIMINATED":2,"FRANCE":3,"TUNISIA":4,"MOROCCO":5,"I-1":6,"I-2":7,"I-3":8,"I-4":9,"CONSTANTINE":10,"II-1":11,"II-2":12,"II-3":13,"III-1":14,"III-2":15,"III-3":16,"ALGIERS":17,"IV-1":18,"IV-2":19,"ORAN":20,"V-1":21,"V-2":22,"V-3":23,"V-4":24,"V-5":25,"V-6":26,"V-7":27,"V-8":28,"VI-1":29,"VI-2":30},"areas":[{"loc":0,"id":"NONE","full_name":"None","name":"None"},{"loc":1,"id":"DEPLOY","full_name":"Deployment","name":"Deployment"},{"loc":2,"id":"ELIMINATED","full_name":"Eliminated","name":"Eliminated"},{"loc":3,"id":"FRANCE","full_name":"France","name":"France","type":4,"zone":null},{"loc":4,"id":"TUNISIA","full_name":"Tunisia","name":"Tunisia","type":4,"zone":"TUNISIA"},{"loc":5,"id":"MOROCCO","full_name":"Morocco","name":"Morocco","type":4,"zone":"MOROCCO"},{"loc":6,"id":"I-1","full_name":"I-1 Barika","name":"Barika","type":1,"zone":"I"},{"loc":7,"id":"I-2","full_name":"I-2 Batna","name":"Batna","type":3,"zone":"I"},{"loc":8,"id":"I-3","full_name":"I-3 Biskra","name":"Biskra","type":3,"zone":"I"},{"loc":9,"id":"I-4","full_name":"I-4 Tebessa","name":"Tebessa","type":1,"zone":"I"},{"loc":10,"id":"CONSTANTINE","full_name":"CONSTANTINE","name":"Constantine","type":2,"zone":"II"},{"loc":11,"id":"II-1","full_name":"II-1 Setif","name":"Setif","type":1,"zone":"II"},{"loc":12,"id":"II-2","full_name":"II-2 Philippeville","name":"Philippeville","type":1,"zone":"II"},{"loc":13,"id":"II-3","full_name":"II-3 Souk Ahras","name":"Souk Ahras","type":1,"zone":"II"},{"loc":14,"id":"III-1","full_name":"III-1 Tizi Ouzou","name":"Tizi Ouzou","type":1,"zone":"III"},{"loc":15,"id":"III-2","full_name":"III-2 Bordj Bou Arreridj","name":"Bordj Bou Arreridj","type":1,"zone":"III"},{"loc":16,"id":"III-3","full_name":"III-3 Bougie","name":"Bougie","type":1,"zone":"III"},{"loc":17,"id":"ALGIERS","full_name":"ALGIERS","name":"Algiers","type":2,"zone":"IV"},{"loc":18,"id":"IV-1","full_name":"IV-1 Medea","name":"Medea","type":1,"zone":"IV"},{"loc":19,"id":"IV-2","full_name":"IV-2 Orleansville","name":"Orleansville","type":1,"zone":"IV"},{"loc":20,"id":"ORAN","full_name":"ORAN","name":"Oran","type":2,"zone":"V"},{"loc":21,"id":"V-1","full_name":"V-1 Mecheria","name":"Mecheria","type":3,"zone":"V"},{"loc":22,"id":"V-2","full_name":"V-2 Tlemcen","name":"Tlemcen","type":1,"zone":"V"},{"loc":23,"id":"V-3","full_name":"V-3 Sidi Bel Abbes","name":"Sidi Bel Abbes","type":1,"zone":"V"},{"loc":24,"id":"V-4","full_name":"V-4 Mostaganem","name":"Mostaganem","type":1,"zone":"V"},{"loc":25,"id":"V-5","full_name":"V-5 Saida","name":"Saida","type":3,"zone":"V"},{"loc":26,"id":"V-6","full_name":"V-6 Mascara","name":"Mascara","type":3,"zone":"V"},{"loc":27,"id":"V-7","full_name":"V-7 Ain Sefra","name":"Ain Sefra","type":3,"zone":"V"},{"loc":28,"id":"V-8","full_name":"V-8 Laghouat","name":"Laghouat","type":3,"zone":"V"},{"loc":29,"id":"VI-1","full_name":"VI-1 Sidi Aissa","name":"Sidi Aissa","type":3,"zone":"VI"},{"loc":30,"id":"VI-2","full_name":"VI-2 Ain Qussera","name":"Ain Qussera","type":1,"zone":"VI"}],"zone_areas":{"TUNISIA":[4],"MOROCCO":[5],"I":[6,7,8,9],"II":[10,11,12,13],"III":[14,15,16],"IV":[17,18,19],"V":[20,21,22,23,24,25,26,27,28],"VI":[29,30]},"adjacents":{"4":[7,8,9,13],"5":[21,22,27],"6":[11,15,29],"7":[4],"8":[4,28,29],"9":[4,11,12,13],"11":[6,9,15,16],"12":[9],"13":[4,9],"14":[18],"15":[6,11,18,29],"16":[11],"18":[14,15,29,30],"19":[24,30],"21":[5],"22":[5],"24":[19,30],"26":[30],"27":[5],"28":[8,29,30],"29":[6,8,15,18,28],"30":[18,19,24,26,28]},"units":[{"side":1,"type":0,"name":"French 2nd division","class":"fr_xx_2","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French 4th division","class":"fr_xx_4","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French 9th division","class":"fr_xx_9","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French 12th division","class":"fr_xx_12","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French 13th division","class":"fr_xx_13","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French 14th division","class":"fr_xx_14","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French 19th division","class":"fr_xx_19","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French 20th division","class":"fr_xx_20","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French 21th division","class":"fr_xx_21","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French 29th division","class":"fr_xx_29","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French 27th division","class":"fr_xx_27","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French 5th division","class":"fr_xx_5","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French 7th division","class":"fr_xx_7","evasion_contact":1,"firepower":25},{"side":1,"type":1,"name":"French brigade","class":"fr_x","evasion_contact":1,"firepower":6},{"side":1,"type":1,"name":"French brigade","class":"fr_x","evasion_contact":1,"firepower":6},{"side":1,"type":1,"name":"French brigade","class":"fr_x","evasion_contact":1,"firepower":6},{"side":1,"type":1,"name":"French brigade","class":"fr_x","evasion_contact":1,"firepower":6},{"side":1,"type":2,"name":"French elite brigade","class":"fr_elite_x_para","evasion_contact":2,"firepower":9},{"side":1,"type":2,"name":"French elite brigade","class":"fr_elite_x_para","evasion_contact":2,"firepower":9},{"side":1,"type":2,"name":"French elite brigade","class":"fr_elite_x_para","evasion_contact":2,"firepower":9},{"side":1,"type":2,"name":"French elite brigade","class":"fr_elite_x_inf","evasion_contact":2,"firepower":9},{"side":1,"type":2,"name":"French elite brigade","class":"fr_elite_x_marine","evasion_contact":2,"firepower":9},{"side":1,"type":2,"name":"French elite brigade","class":"fr_elite_x_marine","evasion_contact":2,"firepower":9},{"side":1,"type":2,"name":"French elite brigade","class":"fr_elite_x_marine","evasion_contact":2,"firepower":9},{"side":1,"type":3,"name":"Algerian brigade","class":"alg_x","evasion_contact":1,"firepower":5},{"side":1,"type":3,"name":"Algerian brigade","class":"alg_x","evasion_contact":1,"firepower":5},{"side":1,"type":3,"name":"Algerian brigade","class":"alg_x","evasion_contact":1,"firepower":5},{"side":1,"type":3,"name":"Algerian brigade","class":"alg_x","evasion_contact":1,"firepower":5},{"side":1,"type":3,"name":"Algerian brigade","class":"alg_x","evasion_contact":1,"firepower":5},{"side":1,"type":3,"name":"Algerian brigade","class":"alg_x","evasion_contact":1,"firepower":5},{"side":1,"type":4,"name":"Algerian Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Algerian Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Algerian Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Algerian Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Algerian Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Algerian Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Algerian Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Algerian Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Algerian Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Algerian Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":0,"type":5,"name":"FLN Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"FLN Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"FLN Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"FLN Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"FLN Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"FLN Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"FLN Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"FLN Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"FLN Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"FLN Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"FLN Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"FLN Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":8,"name":"FLN Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"FLN Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"FLN Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"FLN Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"FLN Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"FLN Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"FLN Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"FLN Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"FLN Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"FLN Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"FLN Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"FLN Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"FLN Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"FLN Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"FLN Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"FLN Front","class":"fln_front","evasion_contact":3,"firepower":3}]}
+const data = {"locations":{"NONE":0,"DEPLOY":1,"ELIMINATED":2,"FRANCE":3,"TUNISIA":4,"MOROCCO":5,"I-1":6,"I-2":7,"I-3":8,"I-4":9,"CONSTANTINE":10,"II-1":11,"II-2":12,"II-3":13,"III-1":14,"III-2":15,"III-3":16,"ALGIERS":17,"IV-1":18,"IV-2":19,"ORAN":20,"V-1":21,"V-2":22,"V-3":23,"V-4":24,"V-5":25,"V-6":26,"V-7":27,"V-8":28,"VI-1":29,"VI-2":30},"areas":[{"loc":0,"id":"NONE","full_name":"None","name":"None"},{"loc":1,"id":"DEPLOY","full_name":"Deployment","name":"Deployment"},{"loc":2,"id":"ELIMINATED","full_name":"Eliminated","name":"Eliminated"},{"loc":3,"id":"FRANCE","full_name":"France","name":"France","type":4,"zone":null},{"loc":4,"id":"TUNISIA","full_name":"Tunisia","name":"Tunisia","type":4,"zone":"TUNISIA"},{"loc":5,"id":"MOROCCO","full_name":"Morocco","name":"Morocco","type":4,"zone":"MOROCCO"},{"loc":6,"id":"I-1","full_name":"I-1 Barika","name":"Barika","type":1,"zone":"I"},{"loc":7,"id":"I-2","full_name":"I-2 Batna","name":"Batna","type":3,"zone":"I"},{"loc":8,"id":"I-3","full_name":"I-3 Biskra","name":"Biskra","type":3,"zone":"I"},{"loc":9,"id":"I-4","full_name":"I-4 Tebessa","name":"Tebessa","type":1,"zone":"I"},{"loc":10,"id":"CONSTANTINE","full_name":"CONSTANTINE","name":"Constantine","type":2,"zone":"II"},{"loc":11,"id":"II-1","full_name":"II-1 Setif","name":"Setif","type":1,"zone":"II"},{"loc":12,"id":"II-2","full_name":"II-2 Philippeville","name":"Philippeville","type":1,"zone":"II"},{"loc":13,"id":"II-3","full_name":"II-3 Souk Ahras","name":"Souk Ahras","type":1,"zone":"II"},{"loc":14,"id":"III-1","full_name":"III-1 Tizi Ouzou","name":"Tizi Ouzou","type":1,"zone":"III"},{"loc":15,"id":"III-2","full_name":"III-2 Bordj Bou Arreridj","name":"Bordj Bou Arreridj","type":1,"zone":"III"},{"loc":16,"id":"III-3","full_name":"III-3 Bougie","name":"Bougie","type":1,"zone":"III"},{"loc":17,"id":"ALGIERS","full_name":"ALGIERS","name":"Algiers","type":2,"zone":"IV"},{"loc":18,"id":"IV-1","full_name":"IV-1 Medea","name":"Medea","type":1,"zone":"IV"},{"loc":19,"id":"IV-2","full_name":"IV-2 Orleansville","name":"Orleansville","type":1,"zone":"IV"},{"loc":20,"id":"ORAN","full_name":"ORAN","name":"Oran","type":2,"zone":"V"},{"loc":21,"id":"V-1","full_name":"V-1 Mecheria","name":"Mecheria","type":3,"zone":"V"},{"loc":22,"id":"V-2","full_name":"V-2 Tlemcen","name":"Tlemcen","type":1,"zone":"V"},{"loc":23,"id":"V-3","full_name":"V-3 Sidi Bel Abbes","name":"Sidi Bel Abbes","type":1,"zone":"V"},{"loc":24,"id":"V-4","full_name":"V-4 Mostaganem","name":"Mostaganem","type":1,"zone":"V"},{"loc":25,"id":"V-5","full_name":"V-5 Saida","name":"Saida","type":3,"zone":"V"},{"loc":26,"id":"V-6","full_name":"V-6 Mascara","name":"Mascara","type":3,"zone":"V"},{"loc":27,"id":"V-7","full_name":"V-7 Ain Sefra","name":"Ain Sefra","type":3,"zone":"V"},{"loc":28,"id":"V-8","full_name":"V-8 Laghouat","name":"Laghouat","type":3,"zone":"V"},{"loc":29,"id":"VI-1","full_name":"VI-1 Sidi Aissa","name":"Sidi Aissa","type":3,"zone":"VI"},{"loc":30,"id":"VI-2","full_name":"VI-2 Ain Qussera","name":"Ain Qussera","type":1,"zone":"VI"}],"zone_areas":{"TUNISIA":[4],"MOROCCO":[5],"I":[6,7,8,9],"II":[10,11,12,13],"III":[14,15,16],"IV":[17,18,19],"V":[20,21,22,23,24,25,26,27,28],"VI":[29,30]},"adjacents":{"4":[7,8,9,13],"5":[21,22,27],"6":[11,15,29],"7":[4],"8":[4,28,29],"9":[4,11,12,13],"11":[6,9,15,16],"12":[9],"13":[4,9],"14":[18],"15":[6,11,18,29],"16":[11],"18":[14,15,29,30],"19":[24,30],"21":[5],"22":[5],"24":[19,30],"26":[30],"27":[5],"28":[8,29,30],"29":[6,8,15,18,28],"30":[18,19,24,26,28]},"units":[{"side":1,"type":0,"name":"French division","full_name":"French 2nd division","class":"fr_xx_2","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French division","full_name":"French 4th division","class":"fr_xx_4","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French division","full_name":"French 9th division","class":"fr_xx_9","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French division","full_name":"French 12th division","class":"fr_xx_12","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French division","full_name":"French 13th division","class":"fr_xx_13","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French division","full_name":"French 14th division","class":"fr_xx_14","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French division","full_name":"French 19th division","class":"fr_xx_19","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French division","full_name":"French 20th division","class":"fr_xx_20","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French division","full_name":"French 21th division","class":"fr_xx_21","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French division","full_name":"French 29th division","class":"fr_xx_29","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French division","full_name":"French 27th division","class":"fr_xx_27","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French division","full_name":"French 5th division","class":"fr_xx_5","evasion_contact":1,"firepower":25},{"side":1,"type":0,"name":"French division","full_name":"French 7th division","class":"fr_xx_7","evasion_contact":1,"firepower":25},{"side":1,"type":1,"name":"French brigade","full_name":"French brigade","class":"fr_x","evasion_contact":1,"firepower":6},{"side":1,"type":1,"name":"French brigade","full_name":"French brigade","class":"fr_x","evasion_contact":1,"firepower":6},{"side":1,"type":1,"name":"French brigade","full_name":"French brigade","class":"fr_x","evasion_contact":1,"firepower":6},{"side":1,"type":1,"name":"French brigade","full_name":"French brigade","class":"fr_x","evasion_contact":1,"firepower":6},{"side":1,"type":2,"name":"French elite brigade","full_name":"French elite brigade","class":"fr_elite_x_para","evasion_contact":2,"firepower":9},{"side":1,"type":2,"name":"French elite brigade","full_name":"French elite brigade","class":"fr_elite_x_para","evasion_contact":2,"firepower":9},{"side":1,"type":2,"name":"French elite brigade","full_name":"French elite brigade","class":"fr_elite_x_para","evasion_contact":2,"firepower":9},{"side":1,"type":2,"name":"French elite brigade","full_name":"French elite brigade","class":"fr_elite_x_inf","evasion_contact":2,"firepower":9},{"side":1,"type":2,"name":"French elite brigade","full_name":"French elite brigade","class":"fr_elite_x_marine","evasion_contact":2,"firepower":9},{"side":1,"type":2,"name":"French elite brigade","full_name":"French elite brigade","class":"fr_elite_x_marine","evasion_contact":2,"firepower":9},{"side":1,"type":2,"name":"French elite brigade","full_name":"French elite brigade","class":"fr_elite_x_marine","evasion_contact":2,"firepower":9},{"side":1,"type":3,"name":"Algerian brigade","full_name":"Algerian brigade","class":"alg_x","evasion_contact":1,"firepower":5},{"side":1,"type":3,"name":"Algerian brigade","full_name":"Algerian brigade","class":"alg_x","evasion_contact":1,"firepower":5},{"side":1,"type":3,"name":"Algerian brigade","full_name":"Algerian brigade","class":"alg_x","evasion_contact":1,"firepower":5},{"side":1,"type":3,"name":"Algerian brigade","full_name":"Algerian brigade","class":"alg_x","evasion_contact":1,"firepower":5},{"side":1,"type":3,"name":"Algerian brigade","full_name":"Algerian brigade","class":"alg_x","evasion_contact":1,"firepower":5},{"side":1,"type":3,"name":"Algerian brigade","full_name":"Algerian brigade","class":"alg_x","evasion_contact":1,"firepower":5},{"side":1,"type":4,"name":"Police","full_name":"Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Police","full_name":"Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Police","full_name":"Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Police","full_name":"Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Police","full_name":"Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Police","full_name":"Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Police","full_name":"Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Police","full_name":"Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Police","full_name":"Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":1,"type":4,"name":"Police","full_name":"Police","class":"alg_police","evasion_contact":2,"firepower":2},{"side":0,"type":5,"name":"Failek","full_name":"Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"Failek","full_name":"Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"Failek","full_name":"Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"Failek","full_name":"Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"Failek","full_name":"Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"Failek","full_name":"Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"Failek","full_name":"Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"Failek","full_name":"Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"Failek","full_name":"Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":5,"name":"Failek","full_name":"Failek","class":"fln_failek","evasion_contact":2,"firepower":4},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":6,"name":"Band","full_name":"Band","class":"fln_band","evasion_contact":3,"firepower":2},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":7,"name":"Cadre","full_name":"Cadre","class":"fln_cadre","evasion_contact":4,"firepower":1},{"side":0,"type":8,"name":"Front","full_name":"Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"Front","full_name":"Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"Front","full_name":"Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"Front","full_name":"Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"Front","full_name":"Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"Front","full_name":"Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"Front","full_name":"Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"Front","full_name":"Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"Front","full_name":"Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"Front","full_name":"Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"Front","full_name":"Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"Front","full_name":"Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"Front","full_name":"Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"Front","full_name":"Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"Front","full_name":"Front","class":"fln_front","evasion_contact":3,"firepower":3},{"side":0,"type":8,"name":"Front","full_name":"Front","class":"fln_front","evasion_contact":3,"firepower":3}]}
if (typeof module !== 'undefined') module.exports = data
diff --git a/play.js b/play.js
index 6455535..d2b9dd7 100644
--- a/play.js
+++ b/play.js
@@ -401,7 +401,7 @@ function on_focus_loc(evt) {
}
function on_focus_unit(evt) {
- document.getElementById("status").textContent = data.units[evt.target.my_id].name
+ document.getElementById("status").textContent = data.units[evt.target.my_id].full_name
}
function on_blur(_evt) {
@@ -440,7 +440,7 @@ function layout_track(track, e) {
e.style.left = x + (dx * n) + "px"
e.style.top = y + (dy * n) + "px"
- e.style.zIndex = track * 4 + n
+ e.style.zIndex = n
track_count[track] = n + 1
}
@@ -869,9 +869,11 @@ function on_update() { // eslint-disable-line no-unused-vars
action_button("intelligence", "Intelligence")
action_button("civil_affairs", "Civil Affairs")
action_button("suppression", "Suppression")
- action_button("population_resettlement", "Population Resettlement")
+ //action_button("population_resettlement", "Population Resettlement")
+ action_button("population_resettlement", "Resettlement")
- action_button("gov_mission", "Government Mission")
+ //action_button("gov_mission", "Government Mission")
+ action_button("gov_mission", "Government")
action_button("use_air_point", "Air Point")
action_button("airmobilize", "Airmobilize")
action_button("no_react", "No React")
diff --git a/rules.js b/rules.js
index 28d3d92..eb75a9c 100644
--- a/rules.js
+++ b/rules.js
@@ -34,15 +34,15 @@ const CADRE = 7
const FRONT = 8
const unit_type_name = [
- "French Division",
- "French Brigade",
- "French Elite Brigade",
- "Algerian Brigade",
- "Algerian Police",
- "FLN Failek",
- "FLN Band",
- "FLN Cadre",
- "FLN Front",
+ "French division",
+ "French brigade",
+ "French elite brigade",
+ "Algerian brigade",
+ "Police",
+ "Failek",
+ "Band",
+ "Cadre",
+ "Front",
]
// Free deployment holding box
@@ -561,7 +561,7 @@ function free_unit(u) {
}
function activate_oas() {
- log("Gov. PSL ≤ 30: OAS Activated")
+ log("Gov PSL ≤ 30: OAS Activated")
game.oas = DEPLOY
game.oas_control = -1
}
@@ -577,7 +577,7 @@ function roll_oas_control() {
}
function remove_oas() {
- log("Gov. PSL ≥ 70: OAS Removed")
+ log("Gov PSL ≥ 70: OAS Removed")
game.oas = 0
game.oas_control = -1
}
@@ -1203,7 +1203,7 @@ function goto_game_over(result, victory) {
game.victory = victory
log_h1("Game Over")
log(`FLN PSL ${game.fln_psl}`)
- log(`Gov. PSL ${game.gov_psl}`)
+ log(`Gov PSL ${game.gov_psl}`)
log_br()
log(victory)
return true
@@ -1804,7 +1804,7 @@ function goto_jealousy_and_paranoia() {
}
function goto_elections_in_france() {
- log_event("Elections in France")
+ log_event("Elections in France.")
// Government player rolls on the Coup Table (no DRM) and adds or subtracts
// the number of PSP indicated: no units are mobilized or removed.
roll_coup_table()
@@ -1844,7 +1844,7 @@ states.random_event_un_debate = {
}
function goto_fln_factional_purge() {
- log_event("FLN Factional Purge")
+ log_event("FLN Factional Purge.")
// The Government player chooses one wilaya and rolls 1d6, neutralizing
// that number of FLN units there (the FLN player's choice which ones).
game.phasing = GOV_NAME
@@ -2096,8 +2096,8 @@ states.event_gov_suez_crisis_select_units = {
}
function goto_amnesty() {
- log_event("Amnesty")
- log("Gov. Civil Affairs & Suppression +1 DRM this turn.")
+ log_event("Amnesty.")
+ log("Government Civil Affairs & Suppression +1 DRM this turn.")
game.events.amnesty = true
end_random_event()
}
@@ -2148,7 +2148,7 @@ function goto_gov_reinforcement_phase() {
})
if (is_slow_french_reaction() && game.fln_psl > game.gov_psl) {
- log_h3("French Reaction: FLN PSL > Gov. PSL")
+ log_h3("French Reaction: FLN PSL > Gov PSL")
log_br()
game.events.french_reaction = true
}
@@ -2440,8 +2440,7 @@ states.gov_reinforcement = {
function give_fln_ap() {
// Give AP
- log_h3("Areas under FLN control:")
-
+ log("Areas under FLN control:")
log_br()
for_each_algerian_map_area(loc => {
@@ -2485,6 +2484,7 @@ function give_fln_ap() {
// He gets AP equal to 10% (round fractions up) of his current PSL, minus the number of French Naval Points.
let psl_percentage = Math.ceil(0.10 * game.fln_psl)
let psl_ap = Math.max(psl_percentage - game.naval, 0)
+ log_br()
log(`10% of ${game.fln_psl} PSL (- ${game.naval} Naval PTS)`)
if (psl_ap) {
raise_fln_ap(psl_ap)
@@ -2960,6 +2960,7 @@ states.fln_operations = {
inactive: "to do Operations",
prompt() {
view.prompt = "Operations: Perform a mission with OPS units, let Government perform a mission, or Pass."
+ view.prompt = "Operations."
// check if any FLN missions can actually be performed
view.actions.propaganda = 0
@@ -3720,7 +3721,7 @@ function goto_combat() {
}
log(`FLN firepower ${fln_firepower}`)
game.combat.hits_on_gov = roll_crt(fln_firepower)
- logi(`Hits on Gov. ${game.combat.hits_on_gov}`)
+ logi(`Hits on Gov ${game.combat.hits_on_gov}`)
log_br()
let gov_firepower = 0
@@ -3741,7 +3742,7 @@ function goto_combat() {
let roll = roll_nd6(game.mission_air_pts)
gov_firepower += roll
}
- log(`Gov. firepower ${gov_firepower}${half_str}`)
+ log(`Gov firepower ${gov_firepower}${half_str}`)
game.combat.hits_on_fln = roll_crt(gov_firepower)
logi(`Hits on FLN ${game.combat.hits_on_fln}`)
log_br()
@@ -3780,7 +3781,7 @@ function end_combat() {
// (according to the table, whether implemented or not) are Neutralized (no one is neutralized if equal results).
if (game.combat.hits_on_gov > game.combat.hits_on_fln) {
- logi(`Gov. units neutralized`)
+ logi(`Gov units neutralized`)
for (let u of game.combat.gov_units) {
neutralize_unit(u)
}
@@ -3912,6 +3913,7 @@ states.gov_operations = {
inactive: "to do Operations",
prompt() {
view.prompt = "Operations: Perform a mission, or Pass."
+ view.prompt = "Operations."
// check if any GOV missions can actually be performed
view.actions.flush = 0
@@ -4105,7 +4107,7 @@ states.gov_flush_select_units = {
if (is_unit_airmobile(u) && unit_loc(u) !== loc)
set_unit_loc(u, loc)
}
- log(`Combined Gov. contact ${contact_ratings}`)
+ log(`Combined Gov contact ${contact_ratings}`)
// (DRM: +1 if target unit has an Evasion rating higher than the total Contact ratings involved,
// or Flush is in a Remote area, or if a Terror marker is present; -1 if Flush is in an Urban area).
@@ -4309,7 +4311,7 @@ states.gov_react = {
},
no_react() {
clear_undo()
- log("Gov. doesn't React")
+ log("Gov doesn't React")
end_gov_mission()
},
roll() {
@@ -4393,7 +4395,7 @@ states.gov_intelligence = {
contact_ratings += unit_contact(u)
})
- log(`Combined Gov. contact ${contact_ratings}`)
+ log(`Combined Gov contact ${contact_ratings}`)
// (DRM: +1 if target unit has an Evasion rating higher than the total Contact ratings involved,
// or mission is in a Remote area, or if a Terror marker is present; -1 if mission is in an Urban area).
@@ -4709,14 +4711,14 @@ function determine_control() {
return
}
- log(`A${loc} (FLN ${fln_pts[loc]} - Gov. ${gov_pts[loc]})`)
+ log(`A${loc} (FLN ${fln_pts[loc]} - Gov ${gov_pts[loc]})`)
if (fln_pts[loc] >= 2 * gov_pts[loc]) {
logi(`FLN Control`)
set_area_fln_control(loc)
return
} else if (gov_pts[loc] >= 2 * fln_pts[loc]) {
- logi(`Gov. Control`)
+ logi(`Gov Control`)
set_area_gov_control(loc)
return
}
@@ -4726,7 +4728,7 @@ function determine_control() {
let fln_roll = roll_d6()
logi(`FLN rolled B${fln_roll}`)
let gov_roll = roll_d6()
- logi(`Gov. rolled B${gov_roll}`)
+ logi(`Gov rolled B${gov_roll}`)
let fln_claim = fln_roll <= difference
let gov_claim = gov_roll <= difference
@@ -4735,7 +4737,7 @@ function determine_control() {
logi(`FLN Control`)
set_area_fln_control(loc)
} else if (gov_claim && !fln_claim) {
- logi(`Gov. Control`)
+ logi(`Gov Control`)
set_area_gov_control(loc)
} else {
logi(`Contested`)
@@ -4767,11 +4769,11 @@ function gov_depreciate_asset(title, num_max) {
let loss = depreciation_loss_number(num_max)
let roll = roll_1d6()
if (game.gov_psl <= 30) {
- logi("-1 Gov. PSL ≤ 30")
+ logi("-1 Gov PSL ≤ 30")
roll -= 1
}
if (game.gov_psl >= 70) {
- logi("+1 Gov. PSL ≥ 70")
+ logi("+1 Gov PSL ≥ 70")
roll += 1
}
if (roll <= loss) {
@@ -4837,12 +4839,12 @@ function unit_and_area_recovery() {
roll += 1
}
if (is_gov_unit(u) && game.gov_psl <= 30) {
- logi("-1 Gov. PSL ≤ 30")
+ logi("-1 Gov PSL ≤ 30")
roll -= 1
}
if (is_gov_unit(u)) {
if (game.gov_psl >= 70) {
- logi("+1 Gov. PSL ≥ 70")
+ logi("+1 Gov PSL ≥ 70")
roll += 1
} else if (is_elite_unit(u)) {
logi("+1 Elite")
@@ -5145,7 +5147,7 @@ function final_psl_adjustment() {
if (game.gov_psl <= 30) {
log_br()
- log("Gov. PSL ≤ 30: Coup d'etat?")
+ log("Gov PSL ≤ 30: Coup d'etat?")
let roll = roll_1d6()
if (is_area_france(game.oas)) {
logi("+1 OAS deployed in France")
@@ -5228,7 +5230,7 @@ function continue_final_psl_adjustment() {
gov_control += 1
}
})
- log(`Area control FLN ${fln_control} - Gov. ${gov_control}`)
+ log(`Area control FLN ${fln_control} - Gov ${gov_control}`)
let control_adjust = Math.floor(Math.abs(fln_control - gov_control) / 2)
if (control_adjust > 0) {
if (fln_control > gov_control) {
@@ -5330,7 +5332,7 @@ function log_h2(msg) {
function log_event(msg) {
log_br()
- log(".h3 " + msg)
+ log(msg)
log_br()
}
diff --git a/tools/gendata.js b/tools/gendata.js
index 55e234a..3bfdce2 100644
--- a/tools/gendata.js
+++ b/tools/gendata.js
@@ -130,9 +130,22 @@ const BAND = 6
const CADRE = 7
const FRONT = 8
-function def_unit(side, type, name, klass, evasion_contact, firepower, count = 1) {
+const unit_type_name = [
+ "French division",
+ "French brigade",
+ "French elite brigade",
+ "Algerian brigade",
+ "Police",
+ "Failek",
+ "Band",
+ "Cadre",
+ "Front",
+]
+
+function def_unit(side, type, full_name, className, evasion_contact, firepower, count = 1) {
+ let name = unit_type_name[type]
for (let i = 0; i < count; ++i) {
- units.push({side, type, name, class: klass, evasion_contact, firepower})
+ units.push({side, type, name: name, full_name, class: className, evasion_contact, firepower})
}
}
@@ -157,12 +170,12 @@ def_unit(GOV, EL_X, "French elite brigade", "fr_elite_x_inf", 2, 9)
def_unit(GOV, EL_X, "French elite brigade", "fr_elite_x_marine", 2, 9, 3)
def_unit(GOV, AL_X, "Algerian brigade", "alg_x", 1, 5, 6)
-def_unit(GOV, POL, "Algerian Police", "alg_police", 2, 2, 10)
+def_unit(GOV, POL, "Police", "alg_police", 2, 2, 10)
-def_unit(FLN, FAILEK, "FLN Failek", "fln_failek", 2, 4, 10)
-def_unit(FLN, BAND, "FLN Band", "fln_band", 3, 2, 24)
-def_unit(FLN, CADRE, "FLN Cadre", "fln_cadre", 4, 1, 30)
-def_unit(FLN, FRONT, "FLN Front", "fln_front", 3, 3, 16)
+def_unit(FLN, FAILEK, "Failek", "fln_failek", 2, 4, 10)
+def_unit(FLN, BAND, "Band", "fln_band", 3, 2, 24)
+def_unit(FLN, CADRE, "Cadre", "fln_cadre", 4, 1, 30)
+def_unit(FLN, FRONT, "Front", "fln_front", 3, 3, 16)
console.log("const area_count =", areas.length)
console.log("const unit_count =", units.length)