Web Dev Solutions

Catalin Mititiuc

aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCatalin Mititiuc <webdevcat@proton.me>2024-08-09 20:22:43 -0700
committerCatalin Mititiuc <webdevcat@proton.me>2024-08-09 20:22:43 -0700
commita7925db494ab7db102a7acb6408ca5efcbf2cb08 (patch)
treef0e1abebeff0e259acc32e7cb25c5634d91bd84a /src/radial.js
parent518693844d391b5c0753555b6fafe5810c1c9afb (diff)
Remove random props on map resource window object
Diffstat (limited to 'src/radial.js')
-rw-r--r--src/radial.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/radial.js b/src/radial.js
index 7c7c0f3..0399d77 100644
--- a/src/radial.js
+++ b/src/radial.js
@@ -79,7 +79,7 @@ function radialToScreenCoords({ q, r, s }) {
}
function drawHexes(el, list, renderText = false) {
- for ([key, v] of list) {
+ for (const [key, v] of list) {
const { q, r, s, t } = fromKey(key);
const { x, y } = radialToScreenCoords({ q, r, s });
@@ -146,7 +146,7 @@ function generateRadialCoords(l, { q, r, s, t = 0 } = {}, { left, top, right, bo
function translateCoords(map, translator) {
const translated = new Map();
- for ([key, val] of map) {
+ for (const [key, val] of map) {
const { q, r, s, t } = fromKey(key);
translated.set(toKey(translator({ q, r, s, t })), val);
}
@@ -271,7 +271,7 @@ function drawMapsheet(placementMarker, mapsheet, position) {
({ q: q + position.q, r: r + position.r, s: s + position.s })
);
- for ([coords, v] of buildingHexes) grid.delete(coords);
+ for (const [coords, v] of buildingHexes) grid.delete(coords);
drawHexes(gridContainer, grid);
(mapsheet.features || []).forEach(feature => {