From 3c266f59c5fbb4675d41d57503acc78ce406bf73 Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Sat, 3 Sep 2022 19:42:05 +0200 Subject: Gazala sequence. Cleaned up regions. Style stuff. --- data.js | 2 +- play.html | 52 +++++++++++++++++++++++++++++++++-------- play.js | 18 +++++++++----- rules.js | 71 +++++++++++++++++++++++++------------------------------- tools/gendata.js | 29 ++++++++++------------- 5 files changed, 99 insertions(+), 73 deletions(-) diff --git a/data.js b/data.js index af69fe1..278fa73 100644 --- a/data.js +++ b/data.js @@ -5,7 +5,7 @@ const hex_road = [0,0,0,0,0,0,0,4,4,4,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4, const side_road = [0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,0,4,4,0,0,4,0,4,0,4,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,0,4,4,0,4,4,0,0,0,0,0,0,0,1,4,1,2,4,4,0,4,2,0,4,0,4,4,0,0,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,0,4,1,0,1,1,0,0,1,0,0,2,1,2,2,0,2,2,1,0,4,2,1,2,2,0,2,0,0,4,2,1,4,0,1,4,0,0,4,0,1,4,0,0,4,0,2,4,0,0,4,0,0,4,2,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,4,0,2,0,0,2,0,2,2,0,0,0,0,0,0,0,1,0,0,0,1,0,1,2,0,0,2,1,0,2,1,0,0,1,2,0,0,0,0,0,1,0,0,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,4,0,0,1,2,0,0,0,1,0,1,0,0,0,0,0,0,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,0,0] const hex_name = {"4":"Malta","7":"El Garib","8":"Cyrene","9":"El Gubba","10":"Derna","30":"Tocra","31":"Barce","32":"Marawa","33":"Wadi Cuff","34":"Wadi Cuff E","35":"Gazala","36":"Acroma","37":"Tobruk","38":"Belhamed","39":"Gambut","40":"Bardia","47":"Exited","48":"Return for Refit","49":"Alexandria Queue","54":"Benghazi","55":"Er Regima","56":"Charruba","57":"Charruba E","58":"Mechili","59":"Rotonda Segnali","60":"Sidi Mufta","61":"Bir Harmat","62":"El Adem","63":"Sidi Rezegh","64":"Ft. Capuzzo","65":"Sollum","66":"Buq Buq","67":"Sidi Barrani","68":"Sidi Barrani E","69":"Mersa Matruh","70":"Fuka","71":"El Daba","72":"El Alamein","73":"El Hamam","74":"Alexandria","78":"Ghemines","79":"Skeleidima","80":"Msus","81":"Msus E","82":"Tengeder W","83":"Tengeder","84":"Tengeder E","85":"Bir Hacheim","86":"Retma","87":"Bir Gubi","88":"Gabr Saleh","89":"Sidi Omar","90":"Bir Habata","91":"Sofafi","92":"Sofafi E","93":"Bir el Kenayis","94":"Bir Khalda","95":"Bir Khalda E","96":"Alam Halfa W","97":"Alam Halfa","98":"Alam Halfa E","99":"Map Edge","102":"Return for Refit","103":"Beda Fomm","104":"Antelat","105":"Antelat E","106":"Ben Gania","107":"Ben Gania E","108":"Tengeder SE","109":"Bir Hacheim SW","110":"Bir Hacheim SE","111":"Retma SE","112":"Ft. Maddalena W","113":"Ft. Maddalena","114":"Ft. Maddalena E","115":"Bir Khamsa","116":"Bir el Qatrani","117":"Bir el Qatrani E","118":"Bir el Kenayis SE","119":"Bir Khalda SE","120":"El Himeimat W","121":"El Himeimat","122":"El Himeimat E","123":"El Himeimat E E","127":"El Agheila Queue","128":"Agedabia","129":"Jebel el Matar","130":"Haraga","131":"Haraga E","137":"Ft. Maddalena SW","138":"Ft. Maddalena SE","139":"Bir Khamsa SW","140":"Bir Fuad W","141":"Bir Fuad","142":"Bir Fuad E","147":"El Himeimat E SE","148":"Map Edge","151":"El Agheila","152":"Mersa Brega","153":"El Haseiat","154":"El Haseiat E","155":"Haraga SE","162":"Jarabub Oasis NW","163":"Jarabub Oasis NE","165":"Bir Fuad SW","166":"Bir Fuad SE","176":"Maaten Giofer","177":"Maaten Giofer E","178":"Sahaba","179":"Sahaba E","180":"Jalo Oasis NE","186":"Jarabub Oasis W","187":"Jarabub Oasis","188":"Jarabub Oasis E","189":"Siwa Oasis NE","197":"Map Edge","203":"Jalo Oasis W","204":"Jalo Oasis","205":"Jalo Oasis E","213":"Siwa Oasis"} -const regions = {"Libya":[7,8,9,10,30,31,32,33,34,35,36,37,38,39,40,54,55,56,57,58,59,60,61,62,63,64,78,79,80,81,82,83,84,85,86,87,88,103,104,105,106,107,108,109,110,111,112,113,128,129,130,131,132,133,134,135,136,137,138,151,152,153,154,155,156,157,158,159,160,161,162,176,177,178,179,180,181,182,183,184,185,186,187,200,201,202,203,204,205,206,207,208,209,210,211],"Egypt":[65,66,67,68,69,70,71,72,73,74,89,90,91,92,93,94,95,96,97,98,114,115,116,117,118,119,120,121,122,123,139,140,141,142,143,144,163,164,165,166,167,188,189,190,191,212,213,214,215],"Sidi Omar":[89],"Tobruk":[37],"Sollum":[65],"El Agheila":[151],"Mersa Brega":[152],"East Line":[36,37,38,39,40,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,85,86,87,88,89,90,91,92,93,94,95,96,97,98,112,113,114,115,116,117,118,119,120,121,122,123,137,138,139,140,141,142,143,144,162,163,164,165,166,167,187,188,189,190,191],"West Line":[7,8,9,10,30,31,32,33,34,35,54,55,56,57,58,59,78,79,80,81,82,83,103,104,105,106,107,128,129,130],"Jebel el Akhdar":[7,8,9,32,33,34,56,57],"Sebkha el Segira":[152,176],"Sebket el Jeneinen":[179,203],"Qattara Depression":[144,145,146,168,169,192,193,216,217]} +const regions = {"Libya":[7,8,9,10,30,31,32,33,34,35,36,37,38,39,40,54,55,56,57,58,59,60,61,62,63,64,78,79,80,81,82,83,84,85,86,87,88,103,104,105,106,107,108,109,110,111,112,113,128,129,130,131,132,133,134,135,136,137,138,151,152,153,154,155,156,157,158,159,160,161,162,176,177,178,179,180,181,182,183,184,185,186,187,200,201,202,203,204,205,206,207,208,209,210,211],"Egypt":[65,66,67,68,69,70,71,72,73,74,89,90,91,92,93,94,95,96,97,98,114,115,116,117,118,119,120,121,122,123,139,140,141,142,143,144,163,164,165,166,167,188,189,190,191,212,213,214,215],"East Line":[36,37,38,39,40,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,85,86,87,88,89,90,91,92,93,94,95,96,97,98,112,113,114,115,116,117,118,119,120,121,122,123,137,138,139,140,141,142,143,144,162,163,164,165,166,167,187,188,189,190,191],"West Line":[7,8,9,10,30,31,32,33,34,35,54,55,56,57,58,59,78,79,80,81,82,83,103,104,105,106,107,128,129,130,151,152]} const unit_name = ["Ari","Lit","Tri","Cen","Fas","Bre","Fol","Pav","Tre","Bol","Sav","Pis","Sab","Ita","15/33","21/3","90/580","15/8","21/5","15/115","21/104","90/155","90/346","90/sv288","90/200","90/361","164/382+433","Ram","164/125","88mm/A","88mm/B","50mm","76mm","/104","7","Sher/A","Sher/B","Grant","Matilda/A","Matilda/B","/1AT","1/2","1/22","7/7","10/8","/32AT","7/4","8/24","8/9","10/23","2/3","1/201G","7/22G","7/SG","1/SG","2/SG","44/131+133","51H/152","51H/154","70/14+16","70/23","44/132","6#/B","2#","6#/A","Priest","/B","/C","/D","/A","/Tob","4IN/7m","4IN/3m","10IN/161m","5IN/9+10","10IN/21+25","4IN/11","4IN/5","5IN/29","8IN/18","1SA","1SA/2+5","1SA/1","1SA/3","2SA/4+6","9AU/20","9AU/24","9AU/26","7AU/18","2NZ/4","2NZ/5","2NZ/6","FF/2","/Pol"] const unit_appearance = ["S",11,7,19,17,"S","M","S","S","S","S",19,7,"S",3,"S",5,5,"S",3,"S",3,11,11,7,5,"M","M","M",3,11,5,17,7,4,18,20,12,"T",4,4,10,8,2,16,8,4,20,20,16,"S",10,"T","T",10,"S",16,18,18,"S","S",16,18,6,12,18,14,18,20,8,"T",2,"S",14,14,14,2,2,10,14,8,6,6,8,8,"S",16,16,"T",6,6,6,14,"T"] const unit_max_steps = [4,3,4,3,3,4,4,4,4,3,3,2,2,2,1,1,1,3,3,3,3,3,2,2,2,2,3,3,2,2,2,2,2,2,2,3,3,2,1,1,4,4,4,4,4,3,3,3,3,3,2,3,3,3,2,2,4,4,4,4,3,2,4,3,3,2,4,4,3,2,2,3,2,2,4,4,3,3,3,2,2,4,3,3,3,4,4,4,3,4,4,4,4,3] diff --git a/play.html b/play.html index 45abfbb..38ba172 100644 --- a/play.html +++ b/play.html @@ -279,8 +279,14 @@ td img { vertical-align: middle } /* MAP */ +svg .fortress { + fill: indianred; + stroke: saddlebrown; +} + svg .fortress.axis { - fill: #264; + fill: seagreen; + stroke: darkgreen; } svg .side { @@ -438,7 +444,7 @@ svg #lines line.axis_supply.allied_supply { background-image: url(units-simple.svg); } -.unit.italian, .unit.german { +.unit.axis { background-color: #9aa880; border-color: #899572; box-shadow: 0 0 2px 1px #2d292c80; @@ -449,15 +455,33 @@ svg #lines line.axis_supply.allied_supply { border-color: #b7a889; box-shadow: 0 0 2px 1px #5c3a1e80; } +/* +*/ -.unit.italian.revealed { - background-color: #f9e3b3; +/* +.unit.axis { + background-color: gray; + border-color: dimgray; + box-shadow: 0 0 2px 1px #2226; +} + +.unit.allied { + background-color: indianred; + border-color: brown; + background-color: #a85; + border-color: #642; + box-shadow: 0 0 2px 1px #4116; } +*/ -.unit.german.revealed { +.unit.axis.revealed { background-color: #abba8e; } +.unit.axis.italian.revealed { + background-color: #f9e3b3; +} + .unit.allied.revealed { background-color: #e4d1ab; } @@ -467,7 +491,7 @@ svg #lines line.axis_supply.allied_supply { } .unit.action.hit { - box-shadow: 0 0 0 2px black, 0 0 2px 2px black; + box-shadow: 0 0 0 2px white, 0 0 0 4px black; } .unit.selected { @@ -481,15 +505,15 @@ svg #lines line.axis_supply.allied_supply { } .unit.disrupted { - border-color: black; + border-color: #222; } .unit.unsupplied { - border-color: brown; + border-color: blue; } .unit.disrupted.unsupplied { - border-color: black brown; + border-color: #222 blue; } .unit.r0 { transform: rotate(0deg); } @@ -744,7 +768,7 @@ svg #lines line.axis_supply.allied_supply {
-
+
ROAD BONUS @@ -753,6 +777,14 @@ svg #lines line.axis_supply.allied_supply {
Trail+1
+ +
SUPPLY RANGE +
Highway∞ +
Track3 +
Trail2 +
None1 +
+
UNIT SPEED
diff --git a/play.js b/play.js index 18dc97c..ddb552c 100644 --- a/play.js +++ b/play.js @@ -603,7 +603,7 @@ function build_hexes() { function build_units() { function build_unit(u) { - let nationality = is_german_unit(u) ? "german" : is_italian_unit(u) ? "italian" : "allied" + let nationality = is_axis_unit(u) ? "axis" : "allied" let elt = ui.units[u] = document.createElement("div") elt.className = `unit ${nationality} u${u} r0 m` elt.addEventListener("mousedown", on_click_unit) @@ -700,12 +700,16 @@ function layout_stack(stack, hex, start_x, start_y, wrap, xdir) { e.classList.toggle("r2", r === 2) e.classList.toggle("r3", r === 3) e.classList.toggle("revealed", true) + if (is_italian_unit(u)) + e.classList.toggle("italian", true) } else { e.classList.toggle("r0", false) e.classList.toggle("r1", false) e.classList.toggle("r2", false) e.classList.toggle("r3", false) e.classList.toggle("revealed", false) + if (is_italian_unit(u)) + e.classList.toggle("italian", false) } e.classList.toggle("action", !view.battle && is_unit_action(u)) @@ -814,18 +818,20 @@ function update_map() { let shared = (stack_list[hex][0].length > 0) && (stack_list[hex][1].length > 0) for (let aa = 0; aa < 2; ++aa) { + let this_y = start_y if (stack_list[hex][aa] === ui.focus) { let height = Math.min(wrap, stack_list[hex][aa].length) * 56 - if (start_y + height + 25 > 960) - start_y = 960 - height + 25 + console.log("stack", hex, aa, wrap, stack_list[hex][aa].length, height, this_y + height + 25) + if (this_y + height + 25 > 960) + this_y = 960 - height - 25 } if (shared) { if (aa === 0) - layout_stack(stack_list[hex][aa], hex, start_x - 28, start_y + 2, wrap, -1) + layout_stack(stack_list[hex][aa], hex, start_x - 28, this_y + 2, wrap, -1) else - layout_stack(stack_list[hex][aa], hex, start_x + 28, start_y - 2, wrap, 1) + layout_stack(stack_list[hex][aa], hex, start_x + 28, this_y - 2, wrap, 1) } else { - layout_stack(stack_list[hex][aa], hex, start_x, start_y, wrap, 1) + layout_stack(stack_list[hex][aa], hex, start_x, this_y, wrap, 1) } } diff --git a/rules.js b/rules.js index 1abe86b..ead708f 100644 --- a/rules.js +++ b/rules.js @@ -145,6 +145,8 @@ const MERSA_BREGA = 152 const JALO_OASIS = 204 const JARABUB_OASIS = 187 const SIWA_OASIS = 213 +const SIDI_OMAR = 89 +const SOLLUM = 65 const BARDIA_FT_CAPUZZO = 122 @@ -160,12 +162,9 @@ const MF_ALLIED = 1 const MF_VISIBLE = 2 const MF_REVEAL = 3 -const region_egypt = regions["Egypt"] -const region_egypt_and_libya = regions["Libya"].concat(regions["Egypt"]) -const region_libya_and_sidi_omar = regions["Libya"].concat(regions["Sidi Omar"]) -const region_libya_and_sidi_omar_and_sollum_except_tobruk = regions["Libya"].concat(regions["Sidi Omar"]).concat(regions["Sollum"]).filter(r => r !== TOBRUK) -const region_egypt_and_tobruk = regions["Egypt"].concat(regions["Tobruk"]) -const region_libya_except_tobruk = regions["Libya"].filter(r => r !== TOBRUK) +const EGYPT = regions.Egypt +const LIBYA = regions.Libya +const LIBYA_NO_TOBRUK = LIBYA.filter(r => r !== TOBRUK) function calc_distance(a, b) { let ax = a % hexw, ay = (a / hexw)|0, az = -ax - ay @@ -5540,10 +5539,13 @@ function goto_buildup_point_determination() { function goto_buildup_discard() { log_h2(game.active + " Buildup") - game.state = 'buildup_discard' let hand = player_hand() - if (hand[REAL] + hand[DUMMY] === 0) + if (hand[REAL] + hand[DUMMY] === 0) { goto_buildup_reinforcements() + } else { + game.state = 'buildup_discard' + game.summary = 0 + } } states.buildup_discard = { @@ -5557,12 +5559,13 @@ states.buildup_discard = { }, dummy_card() { push_undo() - log(game.active + " discarded dummy supply.") let hand = player_hand() hand[DUMMY]-- + game.summary++ }, next() { clear_undo() + log(`${game.active} discarded ${game.summary} dummy supply.`) goto_buildup_reinforcements() }, } @@ -5972,10 +5975,7 @@ function end_buildup_spending() { set_enemy_player() goto_buildup_discard() } else { - if (is_pregame_buildup()) - end_pregame_buildup() - else - goto_buildup_resupply() + goto_buildup_resupply() } } @@ -6065,21 +6065,14 @@ states.dismantle3 = { }, } -function end_pregame_buildup() { - if (game.buildup.axis_cards > 0 || game.buildup.allied_cards > 0) { - log_h2("Resupply") - deal_axis_supply_cards(game.buildup.axis_cards) - deal_allied_supply_cards(game.buildup.allied_cards) - } - game.buildup = null - goto_initial_supply_cards() -} - function goto_buildup_resupply() { // Per-scenario allotment let axis_resupply = (game.month <= 10 || game.malta) ? 2 : 3 let allied_resupply = 3 + if (is_pregame_buildup()) + axis_resupply = allied_resupply = 0 + log_h2("Resupply") log(`Shuffled supply cards.`) shuffle_cards() @@ -6333,10 +6326,7 @@ function end_free_deployment() { } else { game.selected = -1 game.summary = null - if (is_pregame_buildup()) - goto_pregame_buildup() - else - goto_initial_supply_cards() + goto_initial_supply_cards() } } @@ -6398,7 +6388,10 @@ function begin_game() { // No buildup first month // No initiative first month - goto_player_turn() + if (is_pregame_buildup()) + goto_pregame_buildup() + else + goto_player_turn() } // === SETUP === @@ -6473,8 +6466,8 @@ const SCENARIOS = { "1940": { start: 1, end: 6, - axis_deployment: sort_deployment_for_axis(region_libya_and_sidi_omar), - allied_deployment: sort_deployment_for_allied(region_egypt), + axis_deployment: sort_deployment_for_axis([...LIBYA, SIDI_OMAR]), + allied_deployment: sort_deployment_for_allied(EGYPT), axis_initial_supply: 6, allied_initial_supply: 3, }, @@ -6482,23 +6475,23 @@ const SCENARIOS = { start: 1, end: 10, axis_deployment: [], - allied_deployment: sort_deployment_for_allied(region_egypt_and_libya), + allied_deployment: sort_deployment_for_allied([...EGYPT, ...LIBYA]), axis_initial_supply: 6, allied_initial_supply: 6, }, "Crusader": { start: 8, end: 10, - axis_deployment: sort_deployment_for_axis(region_libya_and_sidi_omar_and_sollum_except_tobruk), - allied_deployment: sort_deployment_for_allied(region_egypt_and_tobruk), + axis_deployment: sort_deployment_for_axis([...LIBYA_NO_TOBRUK, SIDI_OMAR, SOLLUM]), + allied_deployment: sort_deployment_for_allied([...EGYPT, TOBRUK]), axis_initial_supply: 10, allied_initial_supply: 12, }, "Battleaxe": { start: 4, end: 10, - axis_deployment: sort_deployment_for_axis(region_libya_except_tobruk), - allied_deployment: sort_deployment_for_allied(region_egypt_and_tobruk), + axis_deployment: sort_deployment_for_axis(LIBYA_NO_TOBRUK), + allied_deployment: sort_deployment_for_allied([...EGYPT, TOBRUK]), axis_initial_supply: 4, allied_initial_supply: 8, }, @@ -6506,7 +6499,7 @@ const SCENARIOS = { start: 11, end: 20, axis_deployment: [ EL_AGHEILA, MERSA_BREGA ], - allied_deployment: sort_deployment_for_allied(region_egypt_and_libya), + allied_deployment: sort_deployment_for_allied([...EGYPT, ...LIBYA]), axis_initial_supply: 5, allied_initial_supply: 5, deployment_limit: { @@ -6528,8 +6521,8 @@ const SCENARIOS = { "Pursuit to Alamein": { start: 15, end: 20, - axis_deployment: sort_deployment_for_axis(regions["Libya"]), - allied_deployment: sort_deployment_for_allied(regions["Egypt"]), + axis_deployment: sort_deployment_for_axis(LIBYA), + allied_deployment: sort_deployment_for_allied(EGYPT), axis_initial_supply: 8, allied_initial_supply: 8, }, @@ -6537,7 +6530,7 @@ const SCENARIOS = { start: 1, end: 20, axis_deployment: [], - allied_deployment: sort_deployment_for_allied(region_egypt_and_libya), + allied_deployment: sort_deployment_for_allied([...EGYPT, ...LIBYA]), axis_initial_supply: 6, allied_initial_supply: 6, }, diff --git a/tools/gendata.js b/tools/gendata.js index e93df8a..1b0c85b 100644 --- a/tools/gendata.js +++ b/tools/gendata.js @@ -283,12 +283,6 @@ def_region("Egypt", 163, 167); def_region("Egypt", 188, 191); def_region("Egypt", 212, 215); -def_region("Sidi Omar", 89, 89); -def_region("Tobruk", 37, 37); -def_region("Sollum", 65, 65); -def_region("El Agheila", 151, 151); -def_region("Mersa Brega", 152, 152); - def_region("East Line", 36, 40); def_region("East Line", 60, 74); def_region("East Line", 85, 98); @@ -303,20 +297,21 @@ def_region("West Line", 54, 59); def_region("West Line", 78, 83); def_region("West Line", 103, 107); def_region("West Line", 128, 130); +def_region("West Line", 151, 152); -def_region("Jebel el Akhdar", 7, 9); -def_region("Jebel el Akhdar", 32, 34); -def_region("Jebel el Akhdar", 56, 57); +// def_region("Jebel el Akhdar", 7, 9); +// def_region("Jebel el Akhdar", 32, 34); +// def_region("Jebel el Akhdar", 56, 57); -def_region("Sebkha el Segira", 152, 152); -def_region("Sebkha el Segira", 176, 176); -def_region("Sebket el Jeneinen", 179, 179); -def_region("Sebket el Jeneinen", 203, 203); +// def_region("Sebkha el Segira", 152, 152); +// def_region("Sebkha el Segira", 176, 176); +// def_region("Sebket el Jeneinen", 179, 179); +// def_region("Sebket el Jeneinen", 203, 203); -def_region("Qattara Depression", 144, 146); -def_region("Qattara Depression", 168, 169); -def_region("Qattara Depression", 192, 193); -def_region("Qattara Depression", 216, 217); +// def_region("Qattara Depression", 144, 146); +// def_region("Qattara Depression", 168, 169); +// def_region("Qattara Depression", 192, 193); +// def_region("Qattara Depression", 216, 217); hex_name = { 7: "El Garib", -- cgit v1.2.3