index : btroops | |
Virtual board game-aid for BattleTroops, an infantry combat simulator wargame published by FASA in 1989. |
aboutsummaryrefslogtreecommitdiff |
diff options
author | Catalin Mititiuc <webdevcat@proton.me> | 2024-07-30 21:02:13 -0700 |
---|---|---|
committer | Catalin Mititiuc <webdevcat@proton.me> | 2024-07-30 21:08:00 -0700 |
commit | 1687e0e790d869fe58f86046f5ee093981670c63 (patch) | |
tree | 212e0c3127483ec29774ac237c07e00b26f05086 /src/modules/scenario.js | |
parent | 48e7675eb0583e420dac52be341e505331c05b4b (diff) |
Ok, hover and firing arc doesn't get stuck at all
Not sure about counters
Diffstat (limited to 'src/modules/scenario.js')
-rw-r--r-- | src/modules/scenario.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/modules/scenario.js b/src/modules/scenario.js index 805d0fe..4f72168 100644 --- a/src/modules/scenario.js +++ b/src/modules/scenario.js @@ -97,7 +97,8 @@ export async function build(svg, request) { const scenarioBuildings = scenario.querySelector('.gameboard .buildings'); if (scenarioGrid) { - grid.replaceWith(svg.ownerDocument.importNode(scenarioGrid, true)); + const frontmost = grid.querySelector('.frontmost'); + [...scenarioGrid.children].forEach(child => frontmost.before(svg.ownerDocument.importNode(child, true))); } if (scenarioBuildings) |