diff --git a/.claude/skills/run-openfront/SKILL.md b/.claude/skills/run-openfront/SKILL.md new file mode 100644 index 000000000..bd77820c5 --- /dev/null +++ b/.claude/skills/run-openfront/SKILL.md @@ -0,0 +1,113 @@ +--- +name: run-openfront +description: Build, run, and drive OpenFront locally. Use when asked to run the game, start the dev server, take a screenshot of the UI, verify a client change in the real app, or interact with the running game (lobby, modals, map picker). +--- + +OpenFront is a browser game (Lit + Pixi.js client, Node game server). +Run the dev server with `npm run dev` (serves on **http://localhost:9000**, +not Vite's default 5173), then drive it with headless Chromium via +`.claude/skills/run-openfront/driver.mjs`. All paths are relative to the +repo root. + +## Prerequisites (one-time per machine, no sudo) + +The host (Ubuntu 26.04, headless) has no browser, and Playwright doesn't +support 26.04 yet. `setup.sh` works around both: it installs Playwright +(`--no-save`), downloads the ubuntu24.04 chromium-headless-shell via +`PLAYWRIGHT_HOST_PLATFORM_OVERRIDE`, extracts the missing system libraries +from `.deb` packages into `~/.cache/openfront-run/` (no root needed), and +builds a local fontconfig (the host has no `/etc/fonts`; Skia FATALs +without one). + +```bash +bash .claude/skills/run-openfront/setup.sh +``` + +Deps were installed with `npm run inst` (`npm ci --ignore-scripts`) — do +not use `npm install`. + +## Run the dev server + +```bash +(npm run dev > /tmp/dev.log 2>&1 &) +timeout 60 bash -c 'until curl -sf http://localhost:9000 >/dev/null 2>&1; do sleep 1; done' +``` + +Stop it with `pkill -f "tsx src/server/Server.ts"; pkill -f vite`. +`ECONNREFUSED "Error polling lobby"` lines in `/tmp/dev.log` are normal — +the closed-source API isn't running in dev. + +## Drive it (agent path) + +Smoke flow — home page, open the single-player modal, dump the map-picker +state, screenshot: + +```bash +node .claude/skills/run-openfront/driver.mjs +# screenshots: /tmp/openfront-run/home.png, /tmp/openfront-run/solo-modal.png +``` + +For ad-hoc flows, write a script **inside the repo** (so `playwright` +resolves) importing the driver's helpers: + +```js +import { + launch, + gotoHome, + openSoloModal, +} from "./.claude/skills/run-openfront/driver.mjs"; +const { browser, page } = await launch(); // env/libs/fonts handled here +await gotoHome(page); +await openSoloModal(page); +// Lit components use light DOM — query and read properties directly: +const s = await page.evaluate( + () => document.querySelector("map-picker")?.selectedMap, +); +await browser.close(); +``` + +## Run (human path) + +`npm run dev`, open http://localhost:9000 in a browser. Useless headless. + +## Test + +```bash +npm test # full suite (Vitest) +npx vitest tests/MapConsistency.test.ts --run # single file +``` + +## Gotchas + +- **Vite serves on port 9000**, not 5173 (configured in vite.config.ts). +- **Playwright on Ubuntu 26.04**: `npx playwright install chromium` fails + with "does not support chromium on ubuntu26.04-x64". Fix: + `PLAYWRIGHT_HOST_PLATFORM_OVERRIDE=ubuntu24.04-x64` (setup.sh does this). +- **Browser dies at launch / mid-load**: missing host libs + (`libnspr4.so`, `libatk-1.0.so.0`, …) then a Skia FATAL + (`SkFontMgr_FontConfigInterface.cpp: Not implemented`) from the absent + fontconfig. `launch()` in driver.mjs injects `LD_LIBRARY_PATH` and + `FONTCONFIG_FILE` pointing at `~/.cache/openfront-run/`; diagnose new + missing libs with `DEBUG=pw:browser` and + `ldd .../chrome-headless-shell | grep "not found"`. +- **The single-player button is labeled "SOLO!"**, and the DOM has more + than one (responsive layouts) — use `button:visible` with + `hasText: /solo/i`. +- **Lit + Vite HMR**: custom elements can't be re-registered, so an + already-open tab keeps old component code after an edit. Hard-reload + (or re-`goto`) before judging behavior. +- **`PAGEERROR: ... reading 'inSpawnPhase'`** on the home page is + pre-existing background noise, not your breakage. +- Wait ~3s after `load` before interacting — Lit components render + client-side (driver's `gotoHome` does this). + +## Troubleshooting + +- `Cannot find package 'playwright'` — your script is outside the repo; + module resolution starts at the script's path, not cwd. Move it inside + the repo (anywhere under the root works). +- `Target page, context or browser has been closed` immediately — + re-run `bash .claude/skills/run-openfront/setup.sh` (the + `~/.cache/openfront-run` lib cache is missing or was cleared). +- `EADDRINUSE` on relaunch — a previous dev server is still up: + `pkill -f "tsx src/server/Server.ts"; pkill -f vite`. diff --git a/.claude/skills/run-openfront/driver.mjs b/.claude/skills/run-openfront/driver.mjs new file mode 100644 index 000000000..0f05dded6 --- /dev/null +++ b/.claude/skills/run-openfront/driver.mjs @@ -0,0 +1,75 @@ +// Headless-Chromium driver for OpenFront. Run from the repo root: +// node .claude/skills/run-openfront/driver.mjs # smoke flow +// or import { launch, gotoHome, openSoloModal } from it in an ad-hoc +// script placed inside the repo (so `playwright` resolves from +// node_modules). Requires setup.sh to have been run once on this machine. +import fs from "fs"; +import os from "os"; +import path from "path"; +import { chromium } from "playwright"; + +const CACHE = + process.env.OPENFRONT_RUN_CACHE ?? + path.join(os.homedir(), ".cache", "openfront-run"); +export const BASE_URL = process.env.OPENFRONT_URL ?? "http://localhost:9000"; + +// Launch chromium with the locally-extracted system libraries and fontconfig +// (see setup.sh). Without them the headless shell dies on libnspr4.so, and +// later Skia FATALs on the missing fontconfig. +export async function launch() { + const env = { ...process.env }; + const libs = path.join(CACHE, "extracted", "usr", "lib", "x86_64-linux-gnu"); + if (fs.existsSync(libs)) { + env.LD_LIBRARY_PATH = env.LD_LIBRARY_PATH + ? `${libs}:${env.LD_LIBRARY_PATH}` + : libs; + env.FONTCONFIG_FILE = path.join(CACHE, "fonts.conf"); + } + const browser = await chromium.launch({ + args: ["--no-sandbox", "--disable-gpu"], + env, + }); + const context = await browser.newContext({ + viewport: { width: 1400, height: 1000 }, + }); + const page = await context.newPage(); + page.on("pageerror", (e) => + console.log("PAGEERROR:", e.message.split("\n")[0]), + ); + page.on("crash", () => console.log("PAGE CRASHED")); + return { browser, page }; +} + +export async function gotoHome(page) { + await page.goto(BASE_URL, { waitUntil: "load", timeout: 60000 }); + // Lit components render client-side after load. + await page.waitForTimeout(3000); +} + +// The single-player button is labeled "SOLO!". There are multiple SOLO +// buttons in the DOM (responsive layouts) — only one is visible. +export async function openSoloModal(page) { + await page.locator("button:visible", { hasText: /solo/i }).first().click(); + await page.waitForTimeout(1500); +} + +const isMain = + process.argv[1] && import.meta.url === `file://${process.argv[1]}`; +if (isMain) { + const outDir = "/tmp/openfront-run"; + fs.mkdirSync(outDir, { recursive: true }); + const { browser, page } = await launch(); + await gotoHome(page); + await page.screenshot({ path: `${outDir}/home.png` }); + await openSoloModal(page); + await page.screenshot({ path: `${outDir}/solo-modal.png` }); + // Reach into a Lit component for ground-truth state (light DOM, no shadow + // root — properties are directly on the element). + const picker = await page.evaluate(() => { + const p = document.querySelector("map-picker"); + return { selectedMap: p?.selectedMap, activeTab: p?.activeTab }; + }); + console.log("map-picker state:", JSON.stringify(picker)); + console.log(`screenshots: ${outDir}/home.png ${outDir}/solo-modal.png`); + await browser.close(); +} diff --git a/.claude/skills/run-openfront/setup.sh b/.claude/skills/run-openfront/setup.sh new file mode 100755 index 000000000..e64def911 --- /dev/null +++ b/.claude/skills/run-openfront/setup.sh @@ -0,0 +1,43 @@ +#!/usr/bin/env bash +# One-time per-machine setup for headless-Chromium driving of OpenFront. +# No sudo needed: Playwright's chromium is downloaded with a platform +# override, and its missing system libraries are extracted locally from +# .deb packages. +set -euo pipefail + +CACHE="${OPENFRONT_RUN_CACHE:-$HOME/.cache/openfront-run}" +mkdir -p "$CACHE/debs" "$CACHE/fonts" "$CACHE/fc-cache" + +# 1. Playwright (not a project dependency; --no-save keeps package.json clean) +npm ls playwright > /dev/null 2>&1 || npm install --no-save playwright + +# 2. Chromium headless shell. Playwright refuses to download on Ubuntu 26.04 +# ("does not support chromium on ubuntu26.04-x64"); the ubuntu24.04 build +# is ABI-compatible, so override the host platform. +PLAYWRIGHT_HOST_PLATFORM_OVERRIDE=ubuntu24.04-x64 npx playwright install chromium + +# 3. Shared libraries the headless shell needs that a minimal host lacks +# (found via: ldd chrome-headless-shell | grep "not found"). +( + cd "$CACHE/debs" + apt-get download \ + libnspr4 libnss3 libasound2t64 libatk1.0-0t64 libatk-bridge2.0-0t64 \ + libatspi2.0-0t64 libgbm1 libx11-6 libxcb1 libxcomposite1 libxdamage1 \ + libxext6 libxfixes3 libxrandr2 libxau6 libxdmcp6 libxi6 libxrender1 \ + libxres1 fonts-dejavu-core + for f in *.deb; do dpkg -x "$f" "$CACHE/extracted"; done +) + +# 4. Fonts. This host has no /etc/fonts at all, and Skia FATALs without a +# fontconfig (SkFontMgr_FontConfigInterface.cpp "Not implemented"). +cp "$CACHE/extracted/usr/share/fonts/truetype/dejavu/"*.ttf "$CACHE/fonts/" +cat > "$CACHE/fonts.conf" << CONF + + + + $CACHE/fonts + $CACHE/fc-cache + +CONF + +echo "setup complete: $CACHE" diff --git a/.gitignore b/.gitignore index 0360bcfa7..53cb04671 100644 --- a/.gitignore +++ b/.gitignore @@ -10,7 +10,8 @@ resources/.DS_Store .DS_Store .clinic/ NOTES.md -.claude/ +.claude/* +!.claude/skills/ .idea/ # this is autogenerated by script src/assets/ diff --git a/eslint.config.js b/eslint.config.js index 3168893d5..201abad09 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -13,7 +13,13 @@ const gitignorePath = path.resolve(__dirname, ".gitignore"); /** @type {import('eslint').Linter.Config[]} */ export default [ includeIgnoreFile(gitignorePath), - { ignores: ["src/server/gatekeeper/**", "tests/pathfinding/playground/**"] }, + { + ignores: [ + "src/server/gatekeeper/**", + "tests/pathfinding/playground/**", + ".claude/**", + ], + }, { files: ["**/*.{js,mjs,cjs,ts}"] }, { languageOptions: { globals: { ...globals.browser, ...globals.node } } }, pluginJs.configs.recommended, diff --git a/map-generator/README.md b/map-generator/README.md index cb69dc6e3..2c5c7a584 100644 --- a/map-generator/README.md +++ b/map-generator/README.md @@ -17,11 +17,12 @@ the [Official Openfront Wiki](https://openfront.wiki/Map_Making) ## Creating a new map +Maps are discovered automatically from the `assets/maps/` folders — `info.json` holds everything the game needs to know about a map. + 1. Create a new folder in `assets/maps/` 2. Create `assets/maps//image.png` -3. Create `assets/maps//info.json` with name and countries -4. Add the map name in `main.go` The `` in `{Name: ""},` should match the `` folder at `assets/maps/` -5. Run the generator for your map: `go run . --maps=` +3. Create `assets/maps//info.json` (see below) +4. Run the generator for your map: `go run . --maps=` By default, `go run .` will process all defined maps. @@ -33,12 +34,14 @@ the [Official Openfront Wiki](https://openfront.wiki/Map_Making) `go run . --maps=northamerica,world` -6. Find the output folder at `../resources/maps/` -7. Go back to the root directory: `cd ..` -8. Run Prettier: `npm run format` +5. Find the output folder at `../resources/maps/` +6. Go back to the root directory: `cd ..` +7. Run Prettier: `npm run format` This rewrites ALL files in place. Git figures out which files are actually changed, don't worry. Alternatively, you can either run Prettier per file: `npx prettier --write resources/maps//` or in VSCode install the Prettier extension and per file do Show and run Commands > Format Document. +Alternatively, `npm run gen-maps` (from the root directory) runs the generator for all maps and formats the output in one step. + ## Output Files - `../resources/maps//manifest.json` - JSON metadata containing map dimensions and land tile counts for all scales. @@ -46,6 +49,7 @@ the [Official Openfront Wiki](https://openfront.wiki/Map_Making) - `../resources/maps//map4x.bin` - 1/4 scale (half dimensions) binary map data used for mini-maps. - `../resources/maps//map16x.bin` - 1/16 scale (quarter dimensions) binary map data used for mini-maps. - `../resources/maps//thumbnail.webp` - WebP image thumbnail of the map. +- `../src/core/game/Maps.gen.ts` - Generated TypeScript (`GameMapType`, `mapCategories`, `mapTranslationKeys`, `multiplayerFrequency`) built from every map's info.json. Regenerated on every run, even with `--maps`. ## Command Line Flags @@ -96,7 +100,11 @@ Example: ```json { - "name": "MySampleMap", + "id": "MySampleMap", + "name": "My Sample Map", + "translation_key": "map.mysamplemap", + "categories": ["europe"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [396, 364], @@ -109,7 +117,17 @@ Example: `coordinates` is x/y position of the nation spawn on the map. Origin is at top left, with x extending right and y extending down -`name` is a `CamelCaseName` of your map. It is used to enable the map in-game. +`id` is the `CamelCaseName` of your map. It must match the `assets/maps/` folder name (lowercased) and becomes the `GameMapType` enum key. + +`name` is the map's canonical name — the `GameMapType` enum value. It must never change once the map ships (it is part of the wire format and stored in game records). + +`translation_key` is the key of the map's display name in `../resources/lang/en.json` (`map.`). + +`categories` groups the map in the map picker. Each entry must be one of: `featured`, `world`, `europe`, `asia`, `north_america`, `africa`, `south_america`, `oceania`, `antarctica`, `cosmic`, `tournament`, `other`. Maps that straddle regions (e.g. Black Sea, Bering Strait) can list more than one. Add `featured` to show the map in the featured section of the map picker. + +`multiplayer_frequency` is how many times the map appears in the public multiplayer playlist. Use 0 (or omit) to keep the map out of the regular rotation. + +`featured_rank` (optional, featured maps only) is the map's position in the featured grid (1 = first). Featured maps without a rank sort after ranked ones, alphabetically. `flag` is the code for a country @@ -130,11 +148,12 @@ The country will need to be added to `../src/client/data/countries.json` ## To Enable In-Game -Using the `name` from your json: +`GameMapType`, `mapCategories`, `mapTranslationKeys`, and +`multiplayerFrequency` are generated from the info.json files into +`../src/core/game/Maps.gen.ts` when the map-generator runs — do not edit that +file by hand. The only step outside info.json is: -- Add to GameMapType and mapCategories in `../src/core/game/Game.ts` -- Add to the map playlist in `../src/server/MapPlaylist.ts` -- Add to the `map` translation object in `../resources/lang/en.json` +- Add the map's display name to the `map` translation object in `../resources/lang/en.json` (using your `translation_key`) ## Notes diff --git a/map-generator/assets/maps/achiran/info.json b/map-generator/assets/maps/achiran/info.json index 286d4973e..d5ca0e56d 100644 --- a/map-generator/assets/maps/achiran/info.json +++ b/map-generator/assets/maps/achiran/info.json @@ -1,5 +1,9 @@ { + "id": "Achiran", "name": "Achiran", + "translation_key": "map.achiran", + "categories": ["other"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [785, 985], diff --git a/map-generator/assets/maps/aegean/info.json b/map-generator/assets/maps/aegean/info.json index e6d211c00..48d8e4a20 100644 --- a/map-generator/assets/maps/aegean/info.json +++ b/map-generator/assets/maps/aegean/info.json @@ -1,5 +1,9 @@ { - "name": "aegean", + "id": "Aegean", + "name": "Aegean", + "translation_key": "map.aegean", + "categories": ["europe"], + "multiplayer_frequency": 6, "nations": [ { "coordinates": [786, 1860], diff --git a/map-generator/assets/maps/africa/info.json b/map-generator/assets/maps/africa/info.json index ceedf9f6b..ec716faa2 100644 --- a/map-generator/assets/maps/africa/info.json +++ b/map-generator/assets/maps/africa/info.json @@ -1,5 +1,10 @@ { + "id": "Africa", "name": "Africa", + "translation_key": "map.africa", + "categories": ["featured", "africa"], + "multiplayer_frequency": 7, + "featured_rank": 6, "nations": [ { "coordinates": [1144, 1894], diff --git a/map-generator/assets/maps/alps/info.json b/map-generator/assets/maps/alps/info.json index b47421976..c4708f2fb 100644 --- a/map-generator/assets/maps/alps/info.json +++ b/map-generator/assets/maps/alps/info.json @@ -1,5 +1,9 @@ { + "id": "Alps", "name": "Alps", + "translation_key": "map.alps", + "categories": ["europe"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [740, 620], diff --git a/map-generator/assets/maps/amazonriver/info.json b/map-generator/assets/maps/amazonriver/info.json index 981aead39..be62f0054 100644 --- a/map-generator/assets/maps/amazonriver/info.json +++ b/map-generator/assets/maps/amazonriver/info.json @@ -1,5 +1,9 @@ { + "id": "AmazonRiver", "name": "Amazon River", + "translation_key": "map.amazonriver", + "categories": ["south_america"], + "multiplayer_frequency": 3, "nations": [ { "coordinates": [524, 60], diff --git a/map-generator/assets/maps/antarctica/info.json b/map-generator/assets/maps/antarctica/info.json index b29915b92..877bda1de 100644 --- a/map-generator/assets/maps/antarctica/info.json +++ b/map-generator/assets/maps/antarctica/info.json @@ -1,5 +1,9 @@ { - "name": "antarctica", + "id": "Antarctica", + "name": "Antarctica", + "translation_key": "map.antarctica", + "categories": ["antarctica"], + "multiplayer_frequency": 1, "nations": [ { "coordinates": [1159, 1261], diff --git a/map-generator/assets/maps/archipelagosea/info.json b/map-generator/assets/maps/archipelagosea/info.json index d39d9e82f..f4a528e3e 100644 --- a/map-generator/assets/maps/archipelagosea/info.json +++ b/map-generator/assets/maps/archipelagosea/info.json @@ -1,5 +1,9 @@ { - "name": "Archipelago Sea", + "id": "ArchipelagoSea", + "name": "ArchipelagoSea", + "translation_key": "map.archipelagosea", + "categories": ["europe"], + "multiplayer_frequency": 3, "nations": [ { "coordinates": [145, 767], diff --git a/map-generator/assets/maps/arctic/info.json b/map-generator/assets/maps/arctic/info.json index 7fc2f006a..c9d122020 100644 --- a/map-generator/assets/maps/arctic/info.json +++ b/map-generator/assets/maps/arctic/info.json @@ -1,5 +1,9 @@ { + "id": "Arctic", "name": "Arctic", + "translation_key": "map.arctic", + "categories": ["europe", "north_america"], + "multiplayer_frequency": 6, "nations": [ { "coordinates": [622, 1171], diff --git a/map-generator/assets/maps/asia/info.json b/map-generator/assets/maps/asia/info.json index 42e26a812..307cc1ffa 100644 --- a/map-generator/assets/maps/asia/info.json +++ b/map-generator/assets/maps/asia/info.json @@ -1,5 +1,10 @@ { + "id": "Asia", "name": "Asia", + "translation_key": "map.asia", + "categories": ["featured", "asia"], + "multiplayer_frequency": 6, + "featured_rank": 5, "nations": [ { "coordinates": [165, 422], diff --git a/map-generator/assets/maps/australia/info.json b/map-generator/assets/maps/australia/info.json index 8caec1b3a..8b7c57f95 100644 --- a/map-generator/assets/maps/australia/info.json +++ b/map-generator/assets/maps/australia/info.json @@ -1,5 +1,9 @@ { + "id": "Australia", "name": "Australia", + "translation_key": "map.australia", + "categories": ["oceania"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [460, 720], diff --git a/map-generator/assets/maps/baikal/info.json b/map-generator/assets/maps/baikal/info.json index 6cebf3aab..82475bd0a 100644 --- a/map-generator/assets/maps/baikal/info.json +++ b/map-generator/assets/maps/baikal/info.json @@ -1,5 +1,9 @@ { + "id": "Baikal", "name": "Baikal", + "translation_key": "map.baikal", + "categories": ["asia"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [695, 665], diff --git a/map-generator/assets/maps/baikalnukewars/info.json b/map-generator/assets/maps/baikalnukewars/info.json index c8a3e024d..13fc1d0be 100644 --- a/map-generator/assets/maps/baikalnukewars/info.json +++ b/map-generator/assets/maps/baikalnukewars/info.json @@ -1,10 +1,24 @@ { - "name": "Baikal (Nuke Wars)", + "id": "BaikalNukeWars", + "name": "Baikal Nuke Wars", + "translation_key": "map.baikalnukewars", + "categories": ["other"], + "multiplayer_frequency": 0, "nations": [], "teamGameSpawnAreas": { "2": [ - { "x": 0, "y": 0, "width": 1330, "height": 1564 }, - { "x": 1430, "y": 0, "width": 1070, "height": 1564 } + { + "x": 0, + "y": 0, + "width": 1330, + "height": 1564 + }, + { + "x": 1430, + "y": 0, + "width": 1070, + "height": 1564 + } ] } } diff --git a/map-generator/assets/maps/bajacalifornia/info.json b/map-generator/assets/maps/bajacalifornia/info.json index a670a09ba..4903d2050 100644 --- a/map-generator/assets/maps/bajacalifornia/info.json +++ b/map-generator/assets/maps/bajacalifornia/info.json @@ -1,5 +1,9 @@ { + "id": "BajaCalifornia", "name": "Baja California", + "translation_key": "map.bajacalifornia", + "categories": ["north_america"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [513, 44], diff --git a/map-generator/assets/maps/balkans/info.json b/map-generator/assets/maps/balkans/info.json index 1dda92bf6..e04d6ac0f 100644 --- a/map-generator/assets/maps/balkans/info.json +++ b/map-generator/assets/maps/balkans/info.json @@ -1,5 +1,9 @@ { + "id": "Balkans", "name": "Balkans", + "translation_key": "map.balkans", + "categories": ["europe"], + "multiplayer_frequency": 6, "nations": [ { "coordinates": [122, 281], diff --git a/map-generator/assets/maps/beringsea/info.json b/map-generator/assets/maps/beringsea/info.json index 1fe0e2f65..b59bea066 100644 --- a/map-generator/assets/maps/beringsea/info.json +++ b/map-generator/assets/maps/beringsea/info.json @@ -1,5 +1,9 @@ { + "id": "BeringSea", "name": "Bering Sea", + "translation_key": "map.beringsea", + "categories": ["asia", "north_america"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [1043, 121], diff --git a/map-generator/assets/maps/beringstrait/info.json b/map-generator/assets/maps/beringstrait/info.json index ca93613e2..4e90a79b1 100644 --- a/map-generator/assets/maps/beringstrait/info.json +++ b/map-generator/assets/maps/beringstrait/info.json @@ -1,5 +1,9 @@ { - "name": "BeringStrait", + "id": "BeringStrait", + "name": "Bering Strait", + "translation_key": "map.beringstrait", + "categories": ["asia", "north_america"], + "multiplayer_frequency": 2, "nations": [ { "coordinates": [1297, 287], diff --git a/map-generator/assets/maps/betweentwoseas/info.json b/map-generator/assets/maps/betweentwoseas/info.json index d001eb13c..f811433f1 100644 --- a/map-generator/assets/maps/betweentwoseas/info.json +++ b/map-generator/assets/maps/betweentwoseas/info.json @@ -1,5 +1,9 @@ { - "name": "BetweenTwoSeas", + "id": "BetweenTwoSeas", + "name": "Between Two Seas", + "translation_key": "map.betweentwoseas", + "categories": ["europe", "asia"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [40, 674], diff --git a/map-generator/assets/maps/blacksea/info.json b/map-generator/assets/maps/blacksea/info.json index a06d6be25..fb50633f9 100644 --- a/map-generator/assets/maps/blacksea/info.json +++ b/map-generator/assets/maps/blacksea/info.json @@ -1,5 +1,9 @@ { - "name": "BlackSea", + "id": "BlackSea", + "name": "Black Sea", + "translation_key": "map.blacksea", + "categories": ["europe", "asia"], + "multiplayer_frequency": 6, "nations": [ { "coordinates": [122, 647], diff --git a/map-generator/assets/maps/bosphorusstraits/info.json b/map-generator/assets/maps/bosphorusstraits/info.json index 0d95175a7..bca2eae3e 100644 --- a/map-generator/assets/maps/bosphorusstraits/info.json +++ b/map-generator/assets/maps/bosphorusstraits/info.json @@ -1,5 +1,9 @@ { + "id": "BosphorusStraits", "name": "Bosphorus Straits", + "translation_key": "map.bosphorusstraits", + "categories": ["europe", "asia"], + "multiplayer_frequency": 3, "nations": [ { "coordinates": [564, 245], diff --git a/map-generator/assets/maps/britannia/info.json b/map-generator/assets/maps/britannia/info.json index 5d6ddd2b4..46343bce7 100644 --- a/map-generator/assets/maps/britannia/info.json +++ b/map-generator/assets/maps/britannia/info.json @@ -1,5 +1,9 @@ { + "id": "Britannia", "name": "Britannia", + "translation_key": "map.britannia", + "categories": ["europe"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [1539, 1915], diff --git a/map-generator/assets/maps/britanniaclassic/info.json b/map-generator/assets/maps/britanniaclassic/info.json index fb4146a94..100d53af9 100644 --- a/map-generator/assets/maps/britanniaclassic/info.json +++ b/map-generator/assets/maps/britanniaclassic/info.json @@ -1,5 +1,9 @@ { + "id": "BritanniaClassic", "name": "Britannia Classic", + "translation_key": "map.britanniaclassic", + "categories": ["europe"], + "multiplayer_frequency": 0, "nations": [ { "coordinates": [960, 1258], diff --git a/map-generator/assets/maps/caribbean/info.json b/map-generator/assets/maps/caribbean/info.json index 7d9378dfc..b7589a2d1 100644 --- a/map-generator/assets/maps/caribbean/info.json +++ b/map-generator/assets/maps/caribbean/info.json @@ -1,5 +1,9 @@ { + "id": "Caribbean", "name": "Caribbean", + "translation_key": "map.caribbean", + "categories": ["north_america"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [538, 200], diff --git a/map-generator/assets/maps/caucasus/info.json b/map-generator/assets/maps/caucasus/info.json index 353ee33f4..65004fe6a 100644 --- a/map-generator/assets/maps/caucasus/info.json +++ b/map-generator/assets/maps/caucasus/info.json @@ -1,5 +1,9 @@ { + "id": "Caucasus", "name": "Caucasus", + "translation_key": "map.caucasus", + "categories": ["europe", "asia"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [624, 581], diff --git a/map-generator/assets/maps/choppingblock/info.json b/map-generator/assets/maps/choppingblock/info.json index cb53922b1..c58e8cbf7 100644 --- a/map-generator/assets/maps/choppingblock/info.json +++ b/map-generator/assets/maps/choppingblock/info.json @@ -1,5 +1,9 @@ { + "id": "ChoppingBlock", "name": "Chopping Block", + "translation_key": "map.choppingblock", + "categories": ["other"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [230, 230], @@ -307,14 +311,44 @@ ], "teamGameSpawnAreas": { "2": [ - { "x": 0, "y": 0, "width": 800, "height": 1610 }, - { "x": 809, "y": 0, "width": 800, "height": 1610 } + { + "x": 0, + "y": 0, + "width": 800, + "height": 1610 + }, + { + "x": 809, + "y": 0, + "width": 800, + "height": 1610 + } ], "4": [ - { "x": 0, "y": 0, "width": 800, "height": 800 }, - { "x": 809, "y": 0, "width": 800, "height": 800 }, - { "x": 0, "y": 809, "width": 800, "height": 800 }, - { "x": 809, "y": 809, "width": 800, "height": 800 } + { + "x": 0, + "y": 0, + "width": 800, + "height": 800 + }, + { + "x": 809, + "y": 0, + "width": 800, + "height": 800 + }, + { + "x": 0, + "y": 809, + "width": 800, + "height": 800 + }, + { + "x": 809, + "y": 809, + "width": 800, + "height": 800 + } ] } } diff --git a/map-generator/assets/maps/conakry/info.json b/map-generator/assets/maps/conakry/info.json index 60e1eedd5..97a9c103f 100644 --- a/map-generator/assets/maps/conakry/info.json +++ b/map-generator/assets/maps/conakry/info.json @@ -1,5 +1,9 @@ { + "id": "Conakry", "name": "Conakry", + "translation_key": "map.conakry", + "categories": ["africa"], + "multiplayer_frequency": 3, "nations": [ { "coordinates": [510, 420], diff --git a/map-generator/assets/maps/danishstraits/info.json b/map-generator/assets/maps/danishstraits/info.json index 0265b811e..d92adabea 100644 --- a/map-generator/assets/maps/danishstraits/info.json +++ b/map-generator/assets/maps/danishstraits/info.json @@ -1,5 +1,9 @@ { + "id": "DanishStraits", "name": "Danish Straits", + "translation_key": "map.danishstraits", + "categories": ["europe"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [37, 227], @@ -94,7 +98,6 @@ { "coordinates": [219, 1205], "name": "Hanover", - "flag": "prussia" }, { diff --git a/map-generator/assets/maps/deglaciatedantarctica/info.json b/map-generator/assets/maps/deglaciatedantarctica/info.json index 14c662368..9c1dbc0d6 100644 --- a/map-generator/assets/maps/deglaciatedantarctica/info.json +++ b/map-generator/assets/maps/deglaciatedantarctica/info.json @@ -1,5 +1,9 @@ { + "id": "DeglaciatedAntarctica", "name": "Deglaciated Antarctica", + "translation_key": "map.deglaciatedantarctica", + "categories": ["antarctica"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [1545, 785], diff --git a/map-generator/assets/maps/didier/info.json b/map-generator/assets/maps/didier/info.json index 38a55f8d0..92c5ff2b3 100644 --- a/map-generator/assets/maps/didier/info.json +++ b/map-generator/assets/maps/didier/info.json @@ -1,5 +1,9 @@ { + "id": "Didier", "name": "Didier", + "translation_key": "map.didier", + "categories": ["other"], + "multiplayer_frequency": 1, "nations": [ { "coordinates": [478, 163], diff --git a/map-generator/assets/maps/didierfrance/info.json b/map-generator/assets/maps/didierfrance/info.json index 18156fa4c..ba8eae89f 100644 --- a/map-generator/assets/maps/didierfrance/info.json +++ b/map-generator/assets/maps/didierfrance/info.json @@ -1,5 +1,9 @@ { - "name": "Didier (France)", + "id": "DidierFrance", + "name": "Didier France", + "translation_key": "map.didierfrance", + "categories": ["other"], + "multiplayer_frequency": 1, "nations": [ { "coordinates": [120, 680], diff --git a/map-generator/assets/maps/dyslexdria/info.json b/map-generator/assets/maps/dyslexdria/info.json index f92a15ac6..575df15fb 100644 --- a/map-generator/assets/maps/dyslexdria/info.json +++ b/map-generator/assets/maps/dyslexdria/info.json @@ -1,5 +1,9 @@ { + "id": "Dyslexdria", "name": "Dyslexdria", + "translation_key": "map.dyslexdria", + "categories": ["world"], + "multiplayer_frequency": 8, "nations": [ { "coordinates": [2380, 400], diff --git a/map-generator/assets/maps/eastasia/info.json b/map-generator/assets/maps/eastasia/info.json index 64e123f44..2310929a5 100644 --- a/map-generator/assets/maps/eastasia/info.json +++ b/map-generator/assets/maps/eastasia/info.json @@ -1,5 +1,9 @@ { + "id": "EastAsia", "name": "East Asia", + "translation_key": "map.eastasia", + "categories": ["asia"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [1150, 660], diff --git a/map-generator/assets/maps/europe/info.json b/map-generator/assets/maps/europe/info.json index e6b7f6cfd..aacbb1661 100644 --- a/map-generator/assets/maps/europe/info.json +++ b/map-generator/assets/maps/europe/info.json @@ -1,5 +1,10 @@ { + "id": "Europe", "name": "Europe", + "translation_key": "map.europe", + "categories": ["featured", "europe"], + "multiplayer_frequency": 7, + "featured_rank": 2, "nations": [ { "coordinates": [634, 781], diff --git a/map-generator/assets/maps/europeclassic/info.json b/map-generator/assets/maps/europeclassic/info.json index 522cc494f..42387231b 100644 --- a/map-generator/assets/maps/europeclassic/info.json +++ b/map-generator/assets/maps/europeclassic/info.json @@ -1,5 +1,9 @@ { - "name": "Europe", + "id": "EuropeClassic", + "name": "Europe Classic", + "translation_key": "map.europeclassic", + "categories": ["europe"], + "multiplayer_frequency": 0, "nations": [ { "coordinates": [171, 171], diff --git a/map-generator/assets/maps/falklandislands/info.json b/map-generator/assets/maps/falklandislands/info.json index 3be7de628..10350571b 100644 --- a/map-generator/assets/maps/falklandislands/info.json +++ b/map-generator/assets/maps/falklandislands/info.json @@ -1,5 +1,9 @@ { + "id": "FalklandIslands", "name": "Falkland Islands", + "translation_key": "map.falklandislands", + "categories": ["south_america"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [484, 987], diff --git a/map-generator/assets/maps/faroeislands/info.json b/map-generator/assets/maps/faroeislands/info.json index 3bc9f5d6f..6b79447e6 100644 --- a/map-generator/assets/maps/faroeislands/info.json +++ b/map-generator/assets/maps/faroeislands/info.json @@ -1,5 +1,9 @@ { + "id": "FaroeIslands", "name": "Faroe Islands", + "translation_key": "map.faroeislands", + "categories": ["europe"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [920, 1780], diff --git a/map-generator/assets/maps/fourislands/info.json b/map-generator/assets/maps/fourislands/info.json index d313ec59d..bfb49145b 100644 --- a/map-generator/assets/maps/fourislands/info.json +++ b/map-generator/assets/maps/fourislands/info.json @@ -1,5 +1,9 @@ { + "id": "FourIslands", "name": "Four Islands", + "translation_key": "map.fourislands", + "categories": ["other"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [403, 1296], @@ -24,14 +28,44 @@ ], "teamGameSpawnAreas": { "2": [ - { "x": 0, "y": 0, "width": 750, "height": 1500 }, - { "x": 750, "y": 0, "width": 750, "height": 1500 } + { + "x": 0, + "y": 0, + "width": 750, + "height": 1500 + }, + { + "x": 750, + "y": 0, + "width": 750, + "height": 1500 + } ], "4": [ - { "x": 0, "y": 0, "width": 750, "height": 750 }, - { "x": 750, "y": 0, "width": 750, "height": 750 }, - { "x": 0, "y": 750, "width": 750, "height": 750 }, - { "x": 750, "y": 750, "width": 750, "height": 750 } + { + "x": 0, + "y": 0, + "width": 750, + "height": 750 + }, + { + "x": 750, + "y": 0, + "width": 750, + "height": 750 + }, + { + "x": 0, + "y": 750, + "width": 750, + "height": 750 + }, + { + "x": 750, + "y": 750, + "width": 750, + "height": 750 + } ] } } diff --git a/map-generator/assets/maps/gatewaytotheatlantic/info.json b/map-generator/assets/maps/gatewaytotheatlantic/info.json index 4dd53b046..22598f784 100644 --- a/map-generator/assets/maps/gatewaytotheatlantic/info.json +++ b/map-generator/assets/maps/gatewaytotheatlantic/info.json @@ -1,5 +1,9 @@ { - "name": "GatewayToTheAtlantic", + "id": "GatewayToTheAtlantic", + "name": "Gateway to the Atlantic", + "translation_key": "map.gatewaytotheatlantic", + "categories": ["europe"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [2161, 420], diff --git a/map-generator/assets/maps/giantworldmap/info.json b/map-generator/assets/maps/giantworldmap/info.json index a30429463..321cec99c 100644 --- a/map-generator/assets/maps/giantworldmap/info.json +++ b/map-generator/assets/maps/giantworldmap/info.json @@ -1,5 +1,9 @@ { - "name": "Giant_World_Map", + "id": "GiantWorldMap", + "name": "Giant World Map", + "translation_key": "map.giantworldmap", + "categories": ["world"], + "multiplayer_frequency": 0, "nations": [ { "coordinates": [2309, 535], diff --git a/map-generator/assets/maps/greatlakes/info.json b/map-generator/assets/maps/greatlakes/info.json index 830ebddb2..4d87ca8a5 100644 --- a/map-generator/assets/maps/greatlakes/info.json +++ b/map-generator/assets/maps/greatlakes/info.json @@ -1,5 +1,9 @@ { + "id": "GreatLakes", "name": "Great Lakes", + "translation_key": "map.greatlakes", + "categories": ["north_america"], + "multiplayer_frequency": 6, "nations": [ { "coordinates": [38, 326], diff --git a/map-generator/assets/maps/gulfofstlawrence/info.json b/map-generator/assets/maps/gulfofstlawrence/info.json index 98dcb936e..ce62e045f 100644 --- a/map-generator/assets/maps/gulfofstlawrence/info.json +++ b/map-generator/assets/maps/gulfofstlawrence/info.json @@ -1,5 +1,9 @@ { + "id": "GulfOfStLawrence", "name": "Gulf of St. Lawrence", + "translation_key": "map.gulfofstlawrence", + "categories": ["north_america"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [88, 364], diff --git a/map-generator/assets/maps/halkidiki/info.json b/map-generator/assets/maps/halkidiki/info.json index 32970ddff..80d9e0e54 100644 --- a/map-generator/assets/maps/halkidiki/info.json +++ b/map-generator/assets/maps/halkidiki/info.json @@ -1,5 +1,9 @@ { + "id": "Halkidiki", "name": "Halkidiki", + "translation_key": "map.halkidiki", + "categories": ["europe"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [1798, 984], diff --git a/map-generator/assets/maps/hawaii/info.json b/map-generator/assets/maps/hawaii/info.json index cca448029..f19bd8743 100644 --- a/map-generator/assets/maps/hawaii/info.json +++ b/map-generator/assets/maps/hawaii/info.json @@ -1,5 +1,9 @@ { + "id": "Hawaii", "name": "Hawaii", + "translation_key": "map.hawaii", + "categories": ["north_america", "oceania"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [283, 281], diff --git a/map-generator/assets/maps/hongkong/info.json b/map-generator/assets/maps/hongkong/info.json index dbb9dccd1..2e84027b4 100644 --- a/map-generator/assets/maps/hongkong/info.json +++ b/map-generator/assets/maps/hongkong/info.json @@ -1,5 +1,9 @@ { + "id": "HongKong", "name": "Hong Kong", + "translation_key": "map.hongkong", + "categories": ["asia"], + "multiplayer_frequency": 6, "nations": [ { "coordinates": [1592, 1147], diff --git a/map-generator/assets/maps/iceland/info.json b/map-generator/assets/maps/iceland/info.json index 0b0cc3655..cd292a30a 100644 --- a/map-generator/assets/maps/iceland/info.json +++ b/map-generator/assets/maps/iceland/info.json @@ -1,5 +1,9 @@ { + "id": "Iceland", "name": "Iceland", + "translation_key": "map.iceland", + "categories": ["europe"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [455, 1115], diff --git a/map-generator/assets/maps/indiansubcontinent/info.json b/map-generator/assets/maps/indiansubcontinent/info.json index e37c859fc..6cd946cb8 100644 --- a/map-generator/assets/maps/indiansubcontinent/info.json +++ b/map-generator/assets/maps/indiansubcontinent/info.json @@ -1,5 +1,9 @@ { + "id": "IndianSubcontinent", "name": "Indian Subcontinent", + "translation_key": "map.indiansubcontinent", + "categories": ["asia"], + "multiplayer_frequency": 8, "nations": [ { "coordinates": [1601, 840], @@ -69,163 +73,136 @@ { "coordinates": [1051, 1586], "name": "Tamil Nadu", - "flag": "in" }, { "coordinates": [783, 1322], "name": "Karnataka", - "flag": "in" }, { "coordinates": [1057, 1256], "name": "Andhra Pradesh", - "flag": "in" }, { "coordinates": [1007, 1065], "name": "Telangana", - "flag": "in" }, { "coordinates": [787, 998], "name": "Maharashtra", - "flag": "in" }, { "coordinates": [706, 1141], "name": "Goa", - "flag": "in" }, { "coordinates": [1391, 906], "name": "Odisha", - "flag": "in" }, { "coordinates": [565, 892], "name": "Gujarat", - "flag": "in" }, { "coordinates": [961, 717], "name": "Madhya Pradesh", - "flag": "in" }, { "coordinates": [1120, 895], "name": "Chhattisgarh", - "flag": "in" }, { "coordinates": [1508, 825], "name": "West Bengal", - "flag": "in" }, { "coordinates": [1317, 717], "name": "Jharkhand", - "flag": "in" }, { "coordinates": [1379, 608], "name": "Bihar", - "flag": "in" }, { "coordinates": [1519, 506], "name": "Sikkim", - "flag": "Sikkim" }, { "coordinates": [1738, 668], "name": "Assam", - "flag": "in" }, { "coordinates": [1194, 535], "name": "Uttar Pradesh", - "flag": "in" }, { "coordinates": [735, 611], "name": "Rajasthan", - "flag": "in" }, { "coordinates": [1624, 507], "name": "Meghalaya", - "flag": "in" }, { "coordinates": [1658, 759], "name": "Tripura", - "flag": "in" }, { "coordinates": [1790, 834], "name": "Mizoram", - "flag": "in" }, { "coordinates": [1878, 762], "name": "Manipur", - "flag": "in" }, { "coordinates": [1952, 637], "name": "Nagaland", - "flag": "in" }, { "coordinates": [1957, 480], "name": "Arunachal Pradesh", - "flag": "in" }, { "coordinates": [884, 439], "name": "Haryana", - "flag": "in" }, { "coordinates": [840, 305], "name": "Punjab", - "flag": "in" }, { "coordinates": [1082, 384], "name": "Uttarakhand", - "flag": "in" }, { "coordinates": [948, 236], "name": "Himachal Pradesh", - "flag": "in" }, { @@ -236,67 +213,56 @@ { "coordinates": [51, 580], "name": "Iran", - "flag": "ir" }, { "coordinates": [81, 24], "name": "Tajikistan", - "flag": "tj" }, { "coordinates": [978, 550], "name": "New Delhi", - "flag": "in" }, { "coordinates": [468, 692], "name": "Sindh", - "flag": "pk" }, { "coordinates": [309, 529], "name": "Balochistan", - "flag": "pk" }, { "coordinates": [637, 464], "name": "Punjab", - "flag": "pk" }, { "coordinates": [514, 366], "name": "Fata", - "flag": "pk" }, { "coordinates": [616, 224], "name": "Khyber Pakhtunkhwa", - "flag": "pk" }, { "coordinates": [740, 161], "name": "Azad Kashmir", - "flag": "Azad Kashmir" }, { "coordinates": [628, 12], "name": "Gilgit-Baltistan", - "flag": "pk" }, { "coordinates": [1065, 1454], "name": "Puducherry", - "flag": "in" } ] diff --git a/map-generator/assets/maps/italia/info.json b/map-generator/assets/maps/italia/info.json index ea87c2146..19c2793f9 100644 --- a/map-generator/assets/maps/italia/info.json +++ b/map-generator/assets/maps/italia/info.json @@ -1,5 +1,9 @@ { + "id": "Italia", "name": "Italia", + "translation_key": "map.italia", + "categories": ["europe"], + "multiplayer_frequency": 6, "nations": [ { "coordinates": [1038, 993], diff --git a/map-generator/assets/maps/japan/info.json b/map-generator/assets/maps/japan/info.json index f7e2d6999..84f9ad54a 100644 --- a/map-generator/assets/maps/japan/info.json +++ b/map-generator/assets/maps/japan/info.json @@ -1,5 +1,10 @@ { - "name": "japan", + "id": "Japan", + "name": "Japan", + "translation_key": "map.japan", + "categories": ["featured", "asia"], + "multiplayer_frequency": 6, + "featured_rank": 7, "nations": [ { "coordinates": [1895, 288], diff --git a/map-generator/assets/maps/juandefucastrait/info.json b/map-generator/assets/maps/juandefucastrait/info.json index 711ab56c2..27a96a1df 100644 --- a/map-generator/assets/maps/juandefucastrait/info.json +++ b/map-generator/assets/maps/juandefucastrait/info.json @@ -1,5 +1,9 @@ { + "id": "JuanDeFucaStrait", "name": "Juan De Fuca Strait", + "translation_key": "map.juandefucastrait", + "categories": ["north_america"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [1812, 445], diff --git a/map-generator/assets/maps/korea/info.json b/map-generator/assets/maps/korea/info.json index 409caaccb..a08a441e9 100644 --- a/map-generator/assets/maps/korea/info.json +++ b/map-generator/assets/maps/korea/info.json @@ -1,5 +1,9 @@ { + "id": "Korea", "name": "Korea", + "translation_key": "map.korea", + "categories": ["asia"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [849, 1523], diff --git a/map-generator/assets/maps/labyrinth/info.json b/map-generator/assets/maps/labyrinth/info.json index 9dd17dea5..0c6793bba 100644 --- a/map-generator/assets/maps/labyrinth/info.json +++ b/map-generator/assets/maps/labyrinth/info.json @@ -1,5 +1,9 @@ { + "id": "Labyrinth", "name": "Labyrinth", + "translation_key": "map.labyrinth", + "categories": ["other"], + "multiplayer_frequency": 6, "nations": [ { "coordinates": [50, 50], @@ -361,43 +365,178 @@ ], "teamGameSpawnAreas": { "2": [ - { "x": 0, "y": 0, "width": 680, "height": 1355 }, - { "x": 680, "y": 0, "width": 680, "height": 1355 } + { + "x": 0, + "y": 0, + "width": 680, + "height": 1355 + }, + { + "x": 680, + "y": 0, + "width": 680, + "height": 1355 + } ], "3": [ - { "x": 1020, "y": 680, "width": 340, "height": 680 }, - { "x": 0, "y": 680, "width": 340, "height": 680 }, - { "x": 340, "y": 0, "width": 680, "height": 680 } + { + "x": 1020, + "y": 680, + "width": 340, + "height": 680 + }, + { + "x": 0, + "y": 680, + "width": 340, + "height": 680 + }, + { + "x": 340, + "y": 0, + "width": 680, + "height": 680 + } ], "4": [ - { "x": 0, "y": 0, "width": 676, "height": 676 }, - { "x": 680, "y": 0, "width": 676, "height": 676 }, - { "x": 0, "y": 680, "width": 676, "height": 676 }, - { "x": 680, "y": 680, "width": 676, "height": 676 } + { + "x": 0, + "y": 0, + "width": 676, + "height": 676 + }, + { + "x": 680, + "y": 0, + "width": 676, + "height": 676 + }, + { + "x": 0, + "y": 680, + "width": 676, + "height": 676 + }, + { + "x": 680, + "y": 680, + "width": 676, + "height": 676 + } ], "5": [ - { "x": 1088, "y": 453, "width": 272, "height": 453 }, - { "x": 0, "y": 816, "width": 453, "height": 272 }, - { "x": 580, "y": 0, "width": 453, "height": 272 }, - { "x": 580, "y": 1088, "width": 453, "height": 272 }, - { "x": 0, "y": 272, "width": 453, "height": 272 } + { + "x": 1088, + "y": 453, + "width": 272, + "height": 453 + }, + { + "x": 0, + "y": 816, + "width": 453, + "height": 272 + }, + { + "x": 580, + "y": 0, + "width": 453, + "height": 272 + }, + { + "x": 580, + "y": 1088, + "width": 453, + "height": 272 + }, + { + "x": 0, + "y": 272, + "width": 453, + "height": 272 + } ], "6": [ - { "x": 226, "y": 0, "width": 453, "height": 680 }, - { "x": 679, "y": 680, "width": 453, "height": 680 }, - { "x": 226, "y": 680, "width": 453, "height": 680 }, - { "x": 679, "y": 0, "width": 453, "height": 680 }, - { "x": 0, "y": 0, "width": 226, "height": 1360 }, - { "x": 1132, "y": 0, "width": 226, "height": 1360 } + { + "x": 226, + "y": 0, + "width": 453, + "height": 680 + }, + { + "x": 679, + "y": 680, + "width": 453, + "height": 680 + }, + { + "x": 226, + "y": 680, + "width": 453, + "height": 680 + }, + { + "x": 679, + "y": 0, + "width": 453, + "height": 680 + }, + { + "x": 0, + "y": 0, + "width": 226, + "height": 1360 + }, + { + "x": 1132, + "y": 0, + "width": 226, + "height": 1360 + } ], "7": [ - { "x": 510, "y": 1088, "width": 340, "height": 272 }, - { "x": 272, "y": 0, "width": 272, "height": 340 }, - { "x": 816, "y": 0, "width": 272, "height": 340 }, - { "x": 0, "y": 340, "width": 272, "height": 340 }, - { "x": 50, "y": 920, "width": 272, "height": 340 }, - { "x": 1088, "y": 340, "width": 272, "height": 340 }, - { "x": 1038, "y": 920, "width": 272, "height": 340 } + { + "x": 510, + "y": 1088, + "width": 340, + "height": 272 + }, + { + "x": 272, + "y": 0, + "width": 272, + "height": 340 + }, + { + "x": 816, + "y": 0, + "width": 272, + "height": 340 + }, + { + "x": 0, + "y": 340, + "width": 272, + "height": 340 + }, + { + "x": 50, + "y": 920, + "width": 272, + "height": 340 + }, + { + "x": 1088, + "y": 340, + "width": 272, + "height": 340 + }, + { + "x": 1038, + "y": 920, + "width": 272, + "height": 340 + } ] } } diff --git a/map-generator/assets/maps/lemnos/info.json b/map-generator/assets/maps/lemnos/info.json index 3aeb17bce..96148f8b8 100644 --- a/map-generator/assets/maps/lemnos/info.json +++ b/map-generator/assets/maps/lemnos/info.json @@ -1,5 +1,9 @@ { + "id": "Lemnos", "name": "Lemnos", + "translation_key": "map.lemnos", + "categories": ["europe"], + "multiplayer_frequency": 3, "nations": [ { "coordinates": [550, 317], diff --git a/map-generator/assets/maps/lisbon/info.json b/map-generator/assets/maps/lisbon/info.json index 3d4a783a0..b61eb7b69 100644 --- a/map-generator/assets/maps/lisbon/info.json +++ b/map-generator/assets/maps/lisbon/info.json @@ -1,5 +1,9 @@ { + "id": "Lisbon", "name": "Lisbon", + "translation_key": "map.lisbon", + "categories": ["europe"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [750, 630], diff --git a/map-generator/assets/maps/losangeles/info.json b/map-generator/assets/maps/losangeles/info.json index 115a36f07..85e49282f 100644 --- a/map-generator/assets/maps/losangeles/info.json +++ b/map-generator/assets/maps/losangeles/info.json @@ -1,5 +1,9 @@ { + "id": "LosAngeles", "name": "Los Angeles", + "translation_key": "map.losangeles", + "categories": ["north_america"], + "multiplayer_frequency": 8, "nations": [ { "coordinates": [546, 16], diff --git a/map-generator/assets/maps/luna/info.json b/map-generator/assets/maps/luna/info.json index 8c8168b8c..e9cda1b40 100644 --- a/map-generator/assets/maps/luna/info.json +++ b/map-generator/assets/maps/luna/info.json @@ -1,5 +1,9 @@ { + "id": "Luna", "name": "Luna", + "translation_key": "map.luna", + "categories": ["cosmic"], + "multiplayer_frequency": 6, "nations": [ { "coordinates": [265, 662], @@ -46,7 +50,6 @@ "flag": "us", "name": "Artemis II" }, - { "coordinates": [515, 170], "flag": "Russian SSR", @@ -57,7 +60,6 @@ "flag": "Russian SSR", "name": "Luna 21" }, - { "coordinates": [1030, 790], "flag": "Russian SSR", @@ -83,7 +85,6 @@ "flag": "Russian SSR", "name": "Luna 1" }, - { "coordinates": [672, 2323], "flag": "cn", @@ -104,13 +105,11 @@ "flag": "cn", "name": "Chang'e 6" }, - { "coordinates": [830, 745], "flag": "jp", "name": "S.L.I.M." }, - { "coordinates": [400, 3360], "flag": "in", @@ -121,7 +120,6 @@ "flag": "in", "name": "Chandrayaan 1" }, - { "coordinates": [755, 3035], "flag": "", @@ -135,8 +133,18 @@ ], "teamGameSpawnAreas": { "2": [ - { "x": 0, "y": 0, "width": 1308, "height": 1754 }, - { "x": 0, "y": 1754, "width": 1308, "height": 1754 } + { + "x": 0, + "y": 0, + "width": 1308, + "height": 1754 + }, + { + "x": 0, + "y": 1754, + "width": 1308, + "height": 1754 + } ] } } diff --git a/map-generator/assets/maps/manicouagan/info.json b/map-generator/assets/maps/manicouagan/info.json index e5286ae11..2f792728e 100644 --- a/map-generator/assets/maps/manicouagan/info.json +++ b/map-generator/assets/maps/manicouagan/info.json @@ -1,5 +1,9 @@ { + "id": "Manicouagan", "name": "Manicouagan", + "translation_key": "map.manicouagan", + "categories": ["north_america"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [784, 1034], diff --git a/map-generator/assets/maps/marenostrum/info.json b/map-generator/assets/maps/marenostrum/info.json index 1e68ccca4..af51dc323 100644 --- a/map-generator/assets/maps/marenostrum/info.json +++ b/map-generator/assets/maps/marenostrum/info.json @@ -1,5 +1,9 @@ { + "id": "MareNostrum", "name": "Mare Nostrum", + "translation_key": "map.marenostrum", + "categories": ["europe"], + "multiplayer_frequency": 6, "nations": [ { "coordinates": [141, 574], diff --git a/map-generator/assets/maps/mars/info.json b/map-generator/assets/maps/mars/info.json index db7cf417c..2ae834ef8 100644 --- a/map-generator/assets/maps/mars/info.json +++ b/map-generator/assets/maps/mars/info.json @@ -1,5 +1,9 @@ { + "id": "Mars", "name": "Mars", + "translation_key": "map.mars", + "categories": ["cosmic"], + "multiplayer_frequency": 3, "nations": [ { "coordinates": [650, 415], diff --git a/map-generator/assets/maps/mena/info.json b/map-generator/assets/maps/mena/info.json index fdb0dcc79..3aca2ed33 100644 --- a/map-generator/assets/maps/mena/info.json +++ b/map-generator/assets/maps/mena/info.json @@ -1,5 +1,9 @@ { - "name": "MENA", + "id": "Mena", + "name": "Mena", + "translation_key": "map.mena", + "categories": ["asia", "africa"], + "multiplayer_frequency": 6, "nations": [ { "coordinates": [257, 82], diff --git a/map-generator/assets/maps/middleeast/info.json b/map-generator/assets/maps/middleeast/info.json index fc4dddc6a..309b98f53 100644 --- a/map-generator/assets/maps/middleeast/info.json +++ b/map-generator/assets/maps/middleeast/info.json @@ -1,5 +1,9 @@ { + "id": "MiddleEast", "name": "Middle East", + "translation_key": "map.middleeast", + "categories": ["asia"], + "multiplayer_frequency": 8, "nations": [ { "coordinates": [300, 65], diff --git a/map-generator/assets/maps/milkyway/info.json b/map-generator/assets/maps/milkyway/info.json index eb97dd68b..920e3791f 100644 --- a/map-generator/assets/maps/milkyway/info.json +++ b/map-generator/assets/maps/milkyway/info.json @@ -1,5 +1,9 @@ { - "name": "Milky Way", + "id": "MilkyWay", + "name": "MilkyWay", + "translation_key": "map.milkyway", + "categories": ["cosmic"], + "multiplayer_frequency": 8, "nations": [ { "coordinates": [775, 757], diff --git a/map-generator/assets/maps/mississippiriver/info.json b/map-generator/assets/maps/mississippiriver/info.json index b4dac7544..02d042626 100644 --- a/map-generator/assets/maps/mississippiriver/info.json +++ b/map-generator/assets/maps/mississippiriver/info.json @@ -1,5 +1,9 @@ { + "id": "MississippiRiver", "name": "Mississippi River", + "translation_key": "map.mississippiriver", + "categories": ["north_america"], + "multiplayer_frequency": 3, "nations": [ { "coordinates": [390, 269], diff --git a/map-generator/assets/maps/montreal/info.json b/map-generator/assets/maps/montreal/info.json index 85d3756a6..bc3d7532a 100644 --- a/map-generator/assets/maps/montreal/info.json +++ b/map-generator/assets/maps/montreal/info.json @@ -1,5 +1,9 @@ { + "id": "Montreal", "name": "Montreal", + "translation_key": "map.montreal", + "categories": ["north_america"], + "multiplayer_frequency": 6, "nations": [ { "coordinates": [800, 430], diff --git a/map-generator/assets/maps/newyorkcity/info.json b/map-generator/assets/maps/newyorkcity/info.json index c9c554511..a4443efaa 100644 --- a/map-generator/assets/maps/newyorkcity/info.json +++ b/map-generator/assets/maps/newyorkcity/info.json @@ -1,5 +1,9 @@ { + "id": "NewYorkCity", "name": "New York City", + "translation_key": "map.newyorkcity", + "categories": ["north_america"], + "multiplayer_frequency": 3, "nations": [ { "coordinates": [127, 1323], diff --git a/map-generator/assets/maps/niledelta/info.json b/map-generator/assets/maps/niledelta/info.json index 961cb922c..1af28d34b 100644 --- a/map-generator/assets/maps/niledelta/info.json +++ b/map-generator/assets/maps/niledelta/info.json @@ -1,5 +1,9 @@ { + "id": "NileDelta", "name": "Nile Delta", + "translation_key": "map.niledelta", + "categories": ["africa"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [305, 414], diff --git a/map-generator/assets/maps/northamerica/info.json b/map-generator/assets/maps/northamerica/info.json index a196fa2d7..10d429072 100644 --- a/map-generator/assets/maps/northamerica/info.json +++ b/map-generator/assets/maps/northamerica/info.json @@ -1,5 +1,10 @@ { - "name": "NorthAmerica", + "id": "NorthAmerica", + "name": "North America", + "translation_key": "map.northamerica", + "categories": ["featured", "north_america"], + "multiplayer_frequency": 5, + "featured_rank": 3, "nations": [ { "coordinates": [1625, 1040], diff --git a/map-generator/assets/maps/northwestpassage/info.json b/map-generator/assets/maps/northwestpassage/info.json index 2c5297485..e55a84575 100644 --- a/map-generator/assets/maps/northwestpassage/info.json +++ b/map-generator/assets/maps/northwestpassage/info.json @@ -1,5 +1,9 @@ { + "id": "NorthwestPassage", "name": "Northwest Passage", + "translation_key": "map.northwestpassage", + "categories": ["north_america"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [1203, 592], diff --git a/map-generator/assets/maps/oceania/info.json b/map-generator/assets/maps/oceania/info.json index 9ebefdd0f..ad1cce7ab 100644 --- a/map-generator/assets/maps/oceania/info.json +++ b/map-generator/assets/maps/oceania/info.json @@ -1,5 +1,9 @@ { + "id": "Oceania", "name": "Oceania", + "translation_key": "map.oceania", + "categories": ["oceania"], + "multiplayer_frequency": 0, "nations": [ { "coordinates": [515, 690], diff --git a/map-generator/assets/maps/onion/info.json b/map-generator/assets/maps/onion/info.json index ede8d11fc..8c1dcc759 100644 --- a/map-generator/assets/maps/onion/info.json +++ b/map-generator/assets/maps/onion/info.json @@ -1,5 +1,9 @@ { - "name": "onion", + "id": "Onion", + "name": "Onion", + "translation_key": "map.onion", + "categories": ["other"], + "multiplayer_frequency": 2, "nations": [ { "coordinates": [51, 188], diff --git a/map-generator/assets/maps/pangaea/info.json b/map-generator/assets/maps/pangaea/info.json index ecedf3982..dba676b2e 100644 --- a/map-generator/assets/maps/pangaea/info.json +++ b/map-generator/assets/maps/pangaea/info.json @@ -1,5 +1,9 @@ { + "id": "Pangaea", "name": "Pangaea", + "translation_key": "map.pangaea", + "categories": ["other"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [389, 800], diff --git a/map-generator/assets/maps/passage/info.json b/map-generator/assets/maps/passage/info.json index 1f78492d3..dd35950cb 100644 --- a/map-generator/assets/maps/passage/info.json +++ b/map-generator/assets/maps/passage/info.json @@ -1,5 +1,9 @@ { + "id": "Passage", "name": "Passage", + "translation_key": "map.passage", + "categories": ["other"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [256, 80], diff --git a/map-generator/assets/maps/pluto/info.json b/map-generator/assets/maps/pluto/info.json index 8d3cec1e3..5f5ff3496 100644 --- a/map-generator/assets/maps/pluto/info.json +++ b/map-generator/assets/maps/pluto/info.json @@ -1,5 +1,9 @@ { + "id": "Pluto", "name": "Pluto", + "translation_key": "map.pluto", + "categories": ["cosmic"], + "multiplayer_frequency": 6, "nations": [ { "coordinates": [396, 364], diff --git a/map-generator/assets/maps/sanfrancisco/info.json b/map-generator/assets/maps/sanfrancisco/info.json index bc5a4b2c7..8cdda4231 100644 --- a/map-generator/assets/maps/sanfrancisco/info.json +++ b/map-generator/assets/maps/sanfrancisco/info.json @@ -1,5 +1,9 @@ { - "name": "SanFrancisco", + "id": "SanFrancisco", + "name": "San Francisco", + "translation_key": "map.sanfrancisco", + "categories": ["north_america"], + "multiplayer_frequency": 3, "nations": [ { "coordinates": [996, 990], diff --git a/map-generator/assets/maps/sierpinski/info.json b/map-generator/assets/maps/sierpinski/info.json index 0075fc4bc..a6d1fcb57 100644 --- a/map-generator/assets/maps/sierpinski/info.json +++ b/map-generator/assets/maps/sierpinski/info.json @@ -1,5 +1,9 @@ { + "id": "Sierpinski", "name": "Sierpinski", + "translation_key": "map.sierpinski", + "categories": ["other"], + "multiplayer_frequency": 10, "nations": [ { "coordinates": [216, 701], diff --git a/map-generator/assets/maps/southamerica/info.json b/map-generator/assets/maps/southamerica/info.json index 777821c02..0ce0f2b36 100644 --- a/map-generator/assets/maps/southamerica/info.json +++ b/map-generator/assets/maps/southamerica/info.json @@ -1,5 +1,10 @@ { + "id": "SouthAmerica", "name": "South America", + "translation_key": "map.southamerica", + "categories": ["featured", "south_america"], + "multiplayer_frequency": 5, + "featured_rank": 4, "nations": [ { "coordinates": [438, 58], diff --git a/map-generator/assets/maps/southeastasia/info.json b/map-generator/assets/maps/southeastasia/info.json index 9065dcb76..f3eb48188 100644 --- a/map-generator/assets/maps/southeastasia/info.json +++ b/map-generator/assets/maps/southeastasia/info.json @@ -1,5 +1,9 @@ { - "name": "Southeast Asia", + "id": "SoutheastAsia", + "name": "SoutheastAsia", + "translation_key": "map.southeastasia", + "categories": ["asia"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [1319, 76], diff --git a/map-generator/assets/maps/straitofgibraltar/info.json b/map-generator/assets/maps/straitofgibraltar/info.json index c87639aec..e39b89f86 100644 --- a/map-generator/assets/maps/straitofgibraltar/info.json +++ b/map-generator/assets/maps/straitofgibraltar/info.json @@ -1,5 +1,9 @@ { + "id": "StraitOfGibraltar", "name": "Strait of Gibraltar", + "translation_key": "map.straitofgibraltar", + "categories": ["europe", "africa"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [1941, 1031], diff --git a/map-generator/assets/maps/straitofhormuz/info.json b/map-generator/assets/maps/straitofhormuz/info.json index 42d4c172f..7ce84a2cf 100644 --- a/map-generator/assets/maps/straitofhormuz/info.json +++ b/map-generator/assets/maps/straitofhormuz/info.json @@ -1,5 +1,9 @@ { + "id": "StraitOfHormuz", "name": "Strait of Hormuz", + "translation_key": "map.straitofhormuz", + "categories": ["asia"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [837, 356], diff --git a/map-generator/assets/maps/straitofmalacca/info.json b/map-generator/assets/maps/straitofmalacca/info.json index e355a0350..1e9b55826 100644 --- a/map-generator/assets/maps/straitofmalacca/info.json +++ b/map-generator/assets/maps/straitofmalacca/info.json @@ -1,5 +1,9 @@ { + "id": "StraitOfMalacca", "name": "Strait Of Malacca", + "translation_key": "map.straitofmalacca", + "categories": ["asia"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [1268, 730], diff --git a/map-generator/assets/maps/surrounded/info.json b/map-generator/assets/maps/surrounded/info.json index f5ae29d31..64ab0c5ef 100644 --- a/map-generator/assets/maps/surrounded/info.json +++ b/map-generator/assets/maps/surrounded/info.json @@ -1,5 +1,9 @@ { + "id": "Surrounded", "name": "Surrounded", + "translation_key": "map.surrounded", + "categories": ["other"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [1043, 910], diff --git a/map-generator/assets/maps/svalmel/info.json b/map-generator/assets/maps/svalmel/info.json index 35e3c195e..36b7ecaea 100644 --- a/map-generator/assets/maps/svalmel/info.json +++ b/map-generator/assets/maps/svalmel/info.json @@ -1,5 +1,9 @@ { + "id": "Svalmel", "name": "Svalmel", + "translation_key": "map.svalmel", + "categories": ["other"], + "multiplayer_frequency": 8, "nations": [ { "coordinates": [900, 850], diff --git a/map-generator/assets/maps/taiwanstrait/info.json b/map-generator/assets/maps/taiwanstrait/info.json index 9d269d919..99e832689 100644 --- a/map-generator/assets/maps/taiwanstrait/info.json +++ b/map-generator/assets/maps/taiwanstrait/info.json @@ -1,5 +1,9 @@ { + "id": "TaiwanStrait", "name": "Taiwan Strait", + "translation_key": "map.taiwanstrait", + "categories": ["asia"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [694, 26], diff --git a/map-generator/assets/maps/thebox/info.json b/map-generator/assets/maps/thebox/info.json index 8ec49d261..71e59da00 100644 --- a/map-generator/assets/maps/thebox/info.json +++ b/map-generator/assets/maps/thebox/info.json @@ -1,18 +1,74 @@ { - "name": "TheBox", + "id": "TheBox", + "name": "The Box", + "translation_key": "map.thebox", + "categories": ["other"], + "multiplayer_frequency": 3, "nations": [ - { "coordinates": [10, 10], "flag": "", "name": "King of the Corner" }, - { "coordinates": [1024, 300], "flag": "", "name": "Suspicious Ally" }, - { "coordinates": [1650, 400], "flag": "", "name": "Evan The Dev" }, - { "coordinates": [1024, 1024], "flag": "", "name": "Middle Defender" }, - { "coordinates": [350, 1024], "flag": "", "name": "Punch Merchant" }, - { "coordinates": [1700, 1024], "flag": "", "name": "Nuke Thrower" }, - { "coordinates": [400, 1650], "flag": "", "name": "Fullsender" }, - { "coordinates": [1024, 1750], "flag": "", "name": "Factory Builder" }, - { "coordinates": [1650, 1650], "flag": "", "name": "Front Manager" }, - { "coordinates": [700, 700], "flag": "", "name": "Box Fighter" }, - { "coordinates": [1350, 700], "flag": "", "name": "Cage Liberator" }, - { "coordinates": [700, 1350], "flag": "", "name": "Train Trader" }, - { "coordinates": [1350, 1350], "flag": "", "name": "Non-peaceful Bot" } + { + "coordinates": [10, 10], + "flag": "", + "name": "King of the Corner" + }, + { + "coordinates": [1024, 300], + "flag": "", + "name": "Suspicious Ally" + }, + { + "coordinates": [1650, 400], + "flag": "", + "name": "Evan The Dev" + }, + { + "coordinates": [1024, 1024], + "flag": "", + "name": "Middle Defender" + }, + { + "coordinates": [350, 1024], + "flag": "", + "name": "Punch Merchant" + }, + { + "coordinates": [1700, 1024], + "flag": "", + "name": "Nuke Thrower" + }, + { + "coordinates": [400, 1650], + "flag": "", + "name": "Fullsender" + }, + { + "coordinates": [1024, 1750], + "flag": "", + "name": "Factory Builder" + }, + { + "coordinates": [1650, 1650], + "flag": "", + "name": "Front Manager" + }, + { + "coordinates": [700, 700], + "flag": "", + "name": "Box Fighter" + }, + { + "coordinates": [1350, 700], + "flag": "", + "name": "Cage Liberator" + }, + { + "coordinates": [700, 1350], + "flag": "", + "name": "Train Trader" + }, + { + "coordinates": [1350, 1350], + "flag": "", + "name": "Non-peaceful Bot" + } ] } diff --git a/map-generator/assets/maps/titan/info.json b/map-generator/assets/maps/titan/info.json index dab88ba02..3fa2deae1 100644 --- a/map-generator/assets/maps/titan/info.json +++ b/map-generator/assets/maps/titan/info.json @@ -1,5 +1,9 @@ { + "id": "Titan", "name": "Titan", + "translation_key": "map.titan", + "categories": ["cosmic"], + "multiplayer_frequency": 3, "nations": [ { "name": "Stone-Keeping Purple Aliens", diff --git a/map-generator/assets/maps/tourney1/info.json b/map-generator/assets/maps/tourney1/info.json index 32fa660fc..13f659d79 100644 --- a/map-generator/assets/maps/tourney1/info.json +++ b/map-generator/assets/maps/tourney1/info.json @@ -1,5 +1,9 @@ { - "name": "Tourney1", + "id": "Tourney1", + "name": "Tourney 2 Teams", + "translation_key": "map.tourney1", + "categories": ["tournament"], + "multiplayer_frequency": 0, "nations": [ { "coordinates": [177, 510], diff --git a/map-generator/assets/maps/tourney2/info.json b/map-generator/assets/maps/tourney2/info.json index f149cd57b..81a498f5c 100644 --- a/map-generator/assets/maps/tourney2/info.json +++ b/map-generator/assets/maps/tourney2/info.json @@ -1,5 +1,9 @@ { - "name": "Tourney2", + "id": "Tourney2", + "name": "Tourney 3 Teams", + "translation_key": "map.tourney2", + "categories": ["tournament"], + "multiplayer_frequency": 0, "nations": [ { "coordinates": [339, 987], diff --git a/map-generator/assets/maps/tourney3/info.json b/map-generator/assets/maps/tourney3/info.json index 1a213ff1f..24713d010 100644 --- a/map-generator/assets/maps/tourney3/info.json +++ b/map-generator/assets/maps/tourney3/info.json @@ -1,5 +1,9 @@ { - "name": "Tourney3", + "id": "Tourney3", + "name": "Tourney 4 Teams", + "translation_key": "map.tourney3", + "categories": ["tournament"], + "multiplayer_frequency": 0, "nations": [ { "coordinates": [437, 410], diff --git a/map-generator/assets/maps/tourney4/info.json b/map-generator/assets/maps/tourney4/info.json index 7c3d7f18d..d41f2f7bb 100644 --- a/map-generator/assets/maps/tourney4/info.json +++ b/map-generator/assets/maps/tourney4/info.json @@ -1,5 +1,9 @@ { - "name": "Tourney4", + "id": "Tourney4", + "name": "Tourney 8 Teams", + "translation_key": "map.tourney4", + "categories": ["tournament"], + "multiplayer_frequency": 0, "nations": [ { "coordinates": [568, 309], diff --git a/map-generator/assets/maps/tradersdream/info.json b/map-generator/assets/maps/tradersdream/info.json index c14927a43..519b4132f 100644 --- a/map-generator/assets/maps/tradersdream/info.json +++ b/map-generator/assets/maps/tradersdream/info.json @@ -1,5 +1,9 @@ { + "id": "TradersDream", "name": "Traders Dream", + "translation_key": "map.tradersdream", + "categories": ["other"], + "multiplayer_frequency": 4, "nations": [ { "coordinates": [1010, 120], diff --git a/map-generator/assets/maps/twolakes/info.json b/map-generator/assets/maps/twolakes/info.json index a390dac12..7c056dbb8 100644 --- a/map-generator/assets/maps/twolakes/info.json +++ b/map-generator/assets/maps/twolakes/info.json @@ -1,5 +1,9 @@ { + "id": "TwoLakes", "name": "Two Lakes", + "translation_key": "map.twolakes", + "categories": ["europe"], + "multiplayer_frequency": 6, "nations": [ { "coordinates": [1025, 750], diff --git a/map-generator/assets/maps/venice/info.json b/map-generator/assets/maps/venice/info.json index 1736c3c20..9854b75d6 100644 --- a/map-generator/assets/maps/venice/info.json +++ b/map-generator/assets/maps/venice/info.json @@ -1,5 +1,9 @@ { + "id": "Venice", "name": "Venice", + "translation_key": "map.venice", + "categories": ["europe"], + "multiplayer_frequency": 6, "nations": [ { "coordinates": [760, 593], diff --git a/map-generator/assets/maps/world/info.json b/map-generator/assets/maps/world/info.json index 71b8ca273..7004adc58 100644 --- a/map-generator/assets/maps/world/info.json +++ b/map-generator/assets/maps/world/info.json @@ -1,5 +1,10 @@ { + "id": "World", "name": "World", + "translation_key": "map.world", + "categories": ["featured", "world"], + "multiplayer_frequency": 20, + "featured_rank": 1, "nations": [ { "coordinates": [484, 284], diff --git a/map-generator/assets/maps/worldinverted/info.json b/map-generator/assets/maps/worldinverted/info.json index a789a8dcd..9b68550be 100644 --- a/map-generator/assets/maps/worldinverted/info.json +++ b/map-generator/assets/maps/worldinverted/info.json @@ -1,5 +1,9 @@ { + "id": "WorldInverted", "name": "World Inverted", + "translation_key": "map.worldinverted", + "categories": ["world"], + "multiplayer_frequency": 8, "nations": [ { "name": "Titan Submersible", @@ -49,7 +53,6 @@ "name": "Atlantis", "flag": "" }, - { "coordinates": [2420, 230], "name": "RMS Lusitania", @@ -250,7 +253,6 @@ "name": "ARA San Juan", "flag": "ar" }, - { "coordinates": [1500, 610], "name": "Pacific", @@ -326,7 +328,6 @@ "name": "Weddell", "flag": "" }, - { "coordinates": [120, 1050], "name": "Weddell Plain", @@ -382,7 +383,6 @@ "name": "Nazca Ridge", "flag": "" }, - { "coordinates": [1450, 333], "name": "Mendocino", @@ -464,7 +464,6 @@ "flag": "" } ], - "additionalNations": [ { "name": "TCG Dumlupınar", @@ -777,7 +776,6 @@ "name": "SS Monroe", "flag": "us" }, - { "name": "Wave Goodbye", "flag": "" @@ -898,7 +896,6 @@ "name": "Red November", "flag": "ussr" }, - { "coordinates": [2326, 303], "name": "Ocean Ranger", @@ -1019,7 +1016,6 @@ "name": "SS Kiche Maru", "flag": "jp" }, - { "coordinates": [2030, 480], "name": "Gulf of Merica", @@ -1295,7 +1291,6 @@ "name": "South-Sandwich", "flag": "" }, - { "coordinates": [1255, 920], "name": "Challenger Bay", diff --git a/map-generator/assets/maps/yellowsea/info.json b/map-generator/assets/maps/yellowsea/info.json index e498efdca..cb2a49830 100644 --- a/map-generator/assets/maps/yellowsea/info.json +++ b/map-generator/assets/maps/yellowsea/info.json @@ -1,5 +1,9 @@ { + "id": "YellowSea", "name": "Yellow Sea", + "translation_key": "map.yellowsea", + "categories": ["asia"], + "multiplayer_frequency": 5, "nations": [ { "coordinates": [1350, 575], diff --git a/map-generator/assets/maps/yenisei/info.json b/map-generator/assets/maps/yenisei/info.json index 0f8e9a154..9a8ac5fad 100644 --- a/map-generator/assets/maps/yenisei/info.json +++ b/map-generator/assets/maps/yenisei/info.json @@ -1,5 +1,9 @@ { + "id": "Yenisei", "name": "Yenisei", + "translation_key": "map.yenisei", + "categories": ["asia"], + "multiplayer_frequency": 6, "nations": [ { "coordinates": [1050, 535], diff --git a/map-generator/codegen.go b/map-generator/codegen.go new file mode 100644 index 000000000..3ca89d304 --- /dev/null +++ b/map-generator/codegen.go @@ -0,0 +1,182 @@ +package main + +import ( + "encoding/json" + "fmt" + "os" + "path/filepath" + "sort" + "strings" +) + +// categoryOrder defines the set of valid "categories" values in info.json and +// the display order of map categories in the generated TypeScript. +var categoryOrder = []string{ + "featured", + "world", + "europe", + "asia", + "north_america", + "africa", + "south_america", + "oceania", + "antarctica", + "cosmic", + "tournament", + "other", +} + +// mapInfo is the subset of info.json fields used for TypeScript generation. +type mapInfo struct { + ID string `json:"id"` + Name string `json:"name"` + TranslationKey string `json:"translation_key"` + Categories []string `json:"categories"` + // How many times the map appears in the multiplayer playlist. + // 0 (or omitted) keeps the map out of the regular rotation. + MultiplayerFrequency int `json:"multiplayer_frequency"` + // Position in the featured grid (1 = first). Featured maps without a + // rank sort after ranked ones, alphabetically. + FeaturedRank int `json:"featured_rank"` +} + +// hasCategory reports whether the map lists the given category. +func (m mapInfo) hasCategory(category string) bool { + for _, c := range m.Categories { + if c == category { + return true + } + } + return false +} + +// generateMapsTS reads every non-test map's info.json and writes the +// GameMapType enum, mapCategories, and mapTranslationKeys to +// src/core/game/Maps.gen.ts. +// Maps appear in registry (alphabetical) order; categories in categoryOrder. +func generateMapsTS() error { + inputDir, err := inputMapDir(false) + if err != nil { + return err + } + cwd, err := os.Getwd() + if err != nil { + return fmt.Errorf("failed to get working directory: %w", err) + } + outPath := filepath.Join(cwd, "..", "src", "core", "game", "Maps.gen.ts") + + infos := make([]mapInfo, 0, len(maps)) + for _, m := range maps { + if m.IsTest { + continue + } + buf, err := os.ReadFile(filepath.Join(inputDir, m.Name, "info.json")) + if err != nil { + return fmt.Errorf("failed to read info.json for %s: %w", m.Name, err) + } + var info mapInfo + if err := json.Unmarshal(buf, &info); err != nil { + return fmt.Errorf("failed to parse info.json for %s: %w", m.Name, err) + } + if info.ID == "" || strings.ToLower(info.ID) != m.Name { + return fmt.Errorf("map %s: info.json \"id\" (%q) must be the folder name in UpperCamelCase", m.Name, info.ID) + } + if info.Name == "" { + return fmt.Errorf("map %s: info.json is missing \"name\"", m.Name) + } + if info.TranslationKey == "" { + return fmt.Errorf("map %s: info.json is missing \"translation_key\"", m.Name) + } + if info.MultiplayerFrequency < 0 { + return fmt.Errorf("map %s: info.json \"multiplayer_frequency\" (%d) must be >= 0", m.Name, info.MultiplayerFrequency) + } + if info.FeaturedRank < 0 { + return fmt.Errorf("map %s: info.json \"featured_rank\" (%d) must be >= 1", m.Name, info.FeaturedRank) + } + if info.FeaturedRank > 0 && !info.hasCategory("featured") { + return fmt.Errorf("map %s: info.json sets \"featured_rank\" but \"categories\" does not include \"featured\"", m.Name) + } + if len(info.Categories) == 0 { + return fmt.Errorf("map %s: info.json \"categories\" must list at least one category", m.Name) + } + seen := make(map[string]bool) + for _, category := range info.Categories { + valid := false + for _, c := range categoryOrder { + if category == c { + valid = true + break + } + } + if !valid { + return fmt.Errorf("map %s: info.json category %q must be one of: %s", m.Name, category, strings.Join(categoryOrder, ", ")) + } + if seen[category] { + return fmt.Errorf("map %s: info.json lists category %q more than once", m.Name, category) + } + seen[category] = true + } + infos = append(infos, info) + } + + var b strings.Builder + b.WriteString("// Code generated by map-generator; DO NOT EDIT.\n") + b.WriteString("// Map metadata lives in map-generator/assets/maps//info.json.\n") + b.WriteString("// Regenerate with `npm run gen-maps`.\n\n") + + b.WriteString("export enum GameMapType {\n") + for _, info := range infos { + // Trailing comment so editors can jump straight to the map's info.json. + b.WriteString(fmt.Sprintf(" %s = %q, // map-generator/assets/maps/%s/info.json\n", + info.ID, info.Name, strings.ToLower(info.ID))) + } + b.WriteString("}\n\n") + + b.WriteString("export type GameMapName = keyof typeof GameMapType;\n\n") + + b.WriteString("export const mapCategories: Record = {\n") + for _, category := range categoryOrder { + members := make([]mapInfo, 0, len(infos)) + for _, info := range infos { + if info.hasCategory(category) { + members = append(members, info) + } + } + if category == "featured" { + sort.SliceStable(members, func(i, j int) bool { + ri, rj := members[i].FeaturedRank, members[j].FeaturedRank + if ri == 0 { + ri = len(infos) + 1 + } + if rj == 0 { + rj = len(infos) + 1 + } + return ri < rj + }) + } + b.WriteString(fmt.Sprintf(" %s: [\n", category)) + for _, info := range members { + b.WriteString(fmt.Sprintf(" GameMapType.%s,\n", info.ID)) + } + b.WriteString(" ],\n") + } + b.WriteString("};\n\n") + + b.WriteString("export const mapTranslationKeys: Record = {\n") + for _, info := range infos { + b.WriteString(fmt.Sprintf(" [GameMapType.%s]: %q,\n", info.ID, info.TranslationKey)) + } + b.WriteString("};\n\n") + + b.WriteString("// How many times each map appears in the multiplayer playlist.\n") + b.WriteString("export const multiplayerFrequency: Record = {\n") + for _, info := range infos { + b.WriteString(fmt.Sprintf(" %s: %d,\n", info.ID, info.MultiplayerFrequency)) + } + b.WriteString("};\n") + + if err := os.WriteFile(outPath, []byte(b.String()), 0644); err != nil { + return fmt.Errorf("failed to write %s: %w", outPath, err) + } + return nil +} diff --git a/map-generator/main.go b/map-generator/main.go index 38099b199..a3997dd2a 100644 --- a/map-generator/main.go +++ b/map-generator/main.go @@ -13,114 +13,38 @@ import ( "sync" ) -// maps defines the registry of available maps to be processed. -// Each entry contains the folder name and a flag indicating if it's a test map. -// -// New maps need to be added here in order to allow the map-generator to process them. -var maps = []struct { +// mapEntry identifies one map to process: its folder name and whether it +// lives in assets/test_maps instead of assets/maps. +type mapEntry struct { Name string IsTest bool -}{ - {Name: "achiran"}, - {Name: "aegean"}, - {Name: "africa"}, - {Name: "alps"}, - {Name: "amazonriver"}, - {Name: "antarctica"}, - {Name: "archipelagosea"}, - {Name: "arctic"}, - {Name: "asia"}, - {Name: "australia"}, - {Name: "baikal"}, - {Name: "baikalnukewars"}, - {Name: "bajacalifornia"}, - {Name: "balkans"}, - {Name: "beringsea"}, - {Name: "beringstrait"}, - {Name: "betweentwoseas"}, - {Name: "blacksea"}, - {Name: "bosphorusstraits"}, - {Name: "britannia"}, - {Name: "britanniaclassic"}, - {Name: "caribbean"}, - {Name: "caucasus"}, - {Name: "choppingblock"}, - {Name: "conakry"}, - {Name: "danishstraits"}, - {Name: "deglaciatedantarctica"}, - {Name: "didier"}, - {Name: "didierfrance"}, - {Name: "dyslexdria"}, - {Name: "eastasia"}, - {Name: "europe"}, - {Name: "europeclassic"}, - {Name: "falklandislands"}, - {Name: "faroeislands"}, - {Name: "fourislands"}, - {Name: "gatewaytotheatlantic"}, - {Name: "giantworldmap"}, - {Name: "greatlakes"}, - {Name: "gulfofstlawrence"}, - {Name: "halkidiki"}, - {Name: "hawaii"}, - {Name: "hongkong"}, - {Name: "iceland"}, - {Name: "indiansubcontinent"}, - {Name: "italia"}, - {Name: "japan"}, - {Name: "juandefucastrait"}, - {Name: "korea"}, - {Name: "labyrinth"}, - {Name: "lemnos"}, - {Name: "lisbon"}, - {Name: "losangeles"}, - {Name: "luna"}, - {Name: "manicouagan"}, - {Name: "marenostrum"}, - {Name: "mars"}, - {Name: "mena"}, - {Name: "middleeast"}, - {Name: "milkyway"}, - {Name: "mississippiriver"}, - {Name: "montreal"}, - {Name: "newyorkcity"}, - {Name: "niledelta"}, - {Name: "northamerica"}, - {Name: "northwestpassage"}, - {Name: "oceania"}, - {Name: "onion"}, - {Name: "pangaea"}, - {Name: "passage"}, - {Name: "pluto"}, - {Name: "sanfrancisco"}, - {Name: "sierpinski"}, - {Name: "southamerica"}, - {Name: "southeastasia"}, - {Name: "straitofgibraltar"}, - {Name: "straitofhormuz"}, - {Name: "straitofmalacca"}, - {Name: "surrounded"}, - {Name: "svalmel"}, - {Name: "taiwanstrait"}, - {Name: "thebox"}, - {Name: "titan"}, - {Name: "tourney1"}, - {Name: "tourney2"}, - {Name: "tourney3"}, - {Name: "tourney4"}, - {Name: "tradersdream"}, - {Name: "twolakes"}, - {Name: "venice"}, - {Name: "world"}, - {Name: "worldinverted"}, - {Name: "yellowsea"}, - {Name: "yenisei"}, - {Name: "big_plains", IsTest: true}, - {Name: "half_land_half_ocean", IsTest: true}, - {Name: "ocean_and_land", IsTest: true}, - {Name: "plains", IsTest: true}, - {Name: "giantworldmap", IsTest: true}, - {Name: "world", IsTest: true}, +} + +// maps holds the registry of maps to process, discovered from the assets +// directories by discoverMaps() at startup. +var maps []mapEntry + +// discoverMaps builds the map registry from the filesystem: every folder in +// assets/maps, plus every folder in assets/test_maps as a test map. Adding a +// map is just adding a folder with image.png and info.json. +func discoverMaps() ([]mapEntry, error) { + var result []mapEntry + for _, isTest := range []bool{false, true} { + dir, err := inputMapDir(isTest) + if err != nil { + return nil, err + } + entries, err := os.ReadDir(dir) + if err != nil { + return nil, fmt.Errorf("failed to read maps directory %s: %w", dir, err) + } + for _, entry := range entries { + if entry.IsDir() { + result = append(result, mapEntry{Name: entry.Name(), IsTest: isTest}) + } + } + } + return result, nil } // mapsFlag holds the comma-separated list of map names passed via the --maps command-line argument. @@ -340,9 +264,19 @@ func main() { slog.SetDefault(logger) + discovered, err := discoverMaps() + if err != nil { + log.Fatalf("Error discovering maps: %v", err) + } + maps = discovered + if err := loadTerrainMaps(); err != nil { log.Fatalf("Error generating terrain maps: %v", err) } + if err := generateMapsTS(); err != nil { + log.Fatalf("Error generating Maps.gen.ts: %v", err) + } + fmt.Println("Terrain maps generated successfully") } diff --git a/map-generator/map-generator b/map-generator/map-generator index 95dd57b0b..c04cb5d6e 100755 Binary files a/map-generator/map-generator and b/map-generator/map-generator differ diff --git a/resources/lang/en.json b/resources/lang/en.json index 664828bf9..e7ae5f614 100644 --- a/resources/lang/en.json +++ b/resources/lang/en.json @@ -620,13 +620,18 @@ }, "map_categories": { "featured": "Featured", - "continental": "Continental", - "regional": "Regional", + "world": "World", + "europe": "Europe", + "asia": "Asia", + "north_america": "North America", + "africa": "Africa", + "south_america": "South America", + "oceania": "Oceania", + "antarctica": "Antarctica", "cosmic": "Cosmic", "tournament": "Tournament", - "fantasy": "Other", + "other": "Other", "special": "Special", - "arcade": "Arcade", "favorites": "Favourites" }, "map_component": { diff --git a/resources/maps/achiran/manifest.json b/resources/maps/achiran/manifest.json index 60e3a6e6b..3640e2849 100644 --- a/resources/maps/achiran/manifest.json +++ b/resources/maps/achiran/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["other"], + "id": "Achiran", "map": { "height": 1700, "num_land_tiles": 1149943, @@ -14,6 +16,7 @@ "num_land_tiles": 284422, "width": 1000 }, + "multiplayer_frequency": 5, "name": "Achiran", "nations": [ { @@ -36,5 +39,6 @@ "flag": "ie", "name": "Achill" } - ] + ], + "translation_key": "map.achiran" } diff --git a/resources/maps/aegean/manifest.json b/resources/maps/aegean/manifest.json index 3f9519162..390f7629c 100644 --- a/resources/maps/aegean/manifest.json +++ b/resources/maps/aegean/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "Aegean", "map": { "height": 2000, "num_land_tiles": 1171283, @@ -14,7 +16,8 @@ "num_land_tiles": 284992, "width": 850 }, - "name": "aegean", + "multiplayer_frequency": 6, + "name": "Aegean", "nations": [ { "coordinates": [786, 1860], @@ -152,5 +155,6 @@ "y": 0 } ] - } + }, + "translation_key": "map.aegean" } diff --git a/resources/maps/africa/manifest.json b/resources/maps/africa/manifest.json index a01cbf81a..71dbf924a 100644 --- a/resources/maps/africa/manifest.json +++ b/resources/maps/africa/manifest.json @@ -1,4 +1,7 @@ { + "categories": ["featured", "africa"], + "featured_rank": 6, + "id": "Africa", "map": { "height": 2032, "num_land_tiles": 2183186, @@ -14,6 +17,7 @@ "num_land_tiles": 537561, "width": 974 }, + "multiplayer_frequency": 7, "name": "Africa", "nations": [ { @@ -196,5 +200,6 @@ "flag": "ga", "name": "Gabon" } - ] + ], + "translation_key": "map.africa" } diff --git a/resources/maps/alps/manifest.json b/resources/maps/alps/manifest.json index 826a3c4f0..942a5c184 100644 --- a/resources/maps/alps/manifest.json +++ b/resources/maps/alps/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "Alps", "map": { "height": 1836, "num_land_tiles": 3672000, @@ -14,6 +16,7 @@ "num_land_tiles": 918000, "width": 1000 }, + "multiplayer_frequency": 4, "name": "Alps", "nations": [ { @@ -56,5 +59,6 @@ "flag": "li", "name": "Liechtenstein" } - ] + ], + "translation_key": "map.alps" } diff --git a/resources/maps/amazonriver/manifest.json b/resources/maps/amazonriver/manifest.json index ee3db179f..cb5af0d25 100644 --- a/resources/maps/amazonriver/manifest.json +++ b/resources/maps/amazonriver/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["south_america"], + "id": "AmazonRiver", "map": { "height": 276, "num_land_tiles": 1150819, @@ -14,6 +16,7 @@ "num_land_tiles": 284639, "width": 2768 }, + "multiplayer_frequency": 3, "name": "Amazon River", "nations": [ { @@ -121,5 +124,6 @@ "flag": "br", "name": "Baia" } - ] + ], + "translation_key": "map.amazonriver" } diff --git a/resources/maps/antarctica/manifest.json b/resources/maps/antarctica/manifest.json index d7c0e9e98..d8f44352d 100644 --- a/resources/maps/antarctica/manifest.json +++ b/resources/maps/antarctica/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["antarctica"], + "id": "Antarctica", "map": { "height": 2000, "num_land_tiles": 1292228, @@ -14,7 +16,8 @@ "num_land_tiles": 320356, "width": 1000 }, - "name": "antarctica", + "multiplayer_frequency": 1, + "name": "Antarctica", "nations": [ { "coordinates": [1159, 1261], @@ -66,5 +69,6 @@ "flag": "Cthulhu Republic", "name": "Ancient Aliens" } - ] + ], + "translation_key": "map.antarctica" } diff --git a/resources/maps/archipelagosea/manifest.json b/resources/maps/archipelagosea/manifest.json index 6fdd8fe7d..53d234682 100644 --- a/resources/maps/archipelagosea/manifest.json +++ b/resources/maps/archipelagosea/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "ArchipelagoSea", "map": { "height": 1508, "num_land_tiles": 287155, @@ -14,7 +16,8 @@ "num_land_tiles": 52779, "width": 1550 }, - "name": "Archipelago Sea", + "multiplayer_frequency": 3, + "name": "ArchipelagoSea", "nations": [ { "coordinates": [145, 767], @@ -116,5 +119,6 @@ "flag": "fi", "name": "Hammarsboda" } - ] + ], + "translation_key": "map.archipelagosea" } diff --git a/resources/maps/arctic/manifest.json b/resources/maps/arctic/manifest.json index fb5d4d555..196672e10 100644 --- a/resources/maps/arctic/manifest.json +++ b/resources/maps/arctic/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe", "north_america"], + "id": "Arctic", "map": { "height": 1828, "num_land_tiles": 1679064, @@ -14,6 +16,7 @@ "num_land_tiles": 409202, "width": 914 }, + "multiplayer_frequency": 6, "name": "Arctic", "nations": [ { @@ -236,5 +239,6 @@ "flag": "fr", "name": "France" } - ] + ], + "translation_key": "map.arctic" } diff --git a/resources/maps/asia/manifest.json b/resources/maps/asia/manifest.json index ad710543e..7943b4b14 100644 --- a/resources/maps/asia/manifest.json +++ b/resources/maps/asia/manifest.json @@ -1,4 +1,7 @@ { + "categories": ["featured", "asia"], + "featured_rank": 5, + "id": "Asia", "map": { "height": 1200, "num_land_tiles": 1079855, @@ -14,6 +17,7 @@ "num_land_tiles": 265625, "width": 1000 }, + "multiplayer_frequency": 6, "name": "Asia", "nations": [ { @@ -141,5 +145,6 @@ "flag": "ua", "name": "Ukraine" } - ] + ], + "translation_key": "map.asia" } diff --git a/resources/maps/australia/manifest.json b/resources/maps/australia/manifest.json index 0a6854c71..5ff81b9a3 100644 --- a/resources/maps/australia/manifest.json +++ b/resources/maps/australia/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["oceania"], + "id": "Australia", "map": { "height": 1500, "num_land_tiles": 1319763, @@ -14,6 +16,7 @@ "num_land_tiles": 328153, "width": 1000 }, + "multiplayer_frequency": 4, "name": "Australia", "nations": [ { @@ -51,5 +54,6 @@ "flag": "aus_tas", "name": "Tasmania" } - ] + ], + "translation_key": "map.australia" } diff --git a/resources/maps/baikal/manifest.json b/resources/maps/baikal/manifest.json index a8ad48387..ee1223299 100644 --- a/resources/maps/baikal/manifest.json +++ b/resources/maps/baikal/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["asia"], + "id": "Baikal", "map": { "height": 1564, "num_land_tiles": 2181746, @@ -14,6 +16,7 @@ "num_land_tiles": 540826, "width": 1250 }, + "multiplayer_frequency": 5, "name": "Baikal", "nations": [ { @@ -87,5 +90,6 @@ "y": 0 } ] - } + }, + "translation_key": "map.baikal" } diff --git a/resources/maps/baikalnukewars/manifest.json b/resources/maps/baikalnukewars/manifest.json index b0f11fbfd..d1cff8fdb 100644 --- a/resources/maps/baikalnukewars/manifest.json +++ b/resources/maps/baikalnukewars/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["other"], + "id": "BaikalNukeWars", "map": { "height": 1564, "num_land_tiles": 1968430, @@ -14,7 +16,8 @@ "num_land_tiles": 488323, "width": 1250 }, - "name": "Baikal (Nuke Wars)", + "multiplayer_frequency": 0, + "name": "Baikal Nuke Wars", "nations": [], "teamGameSpawnAreas": { "2": [ @@ -31,5 +34,6 @@ "y": 0 } ] - } + }, + "translation_key": "map.baikalnukewars" } diff --git a/resources/maps/bajacalifornia/manifest.json b/resources/maps/bajacalifornia/manifest.json index 4de8f7770..2c0e016b8 100644 --- a/resources/maps/bajacalifornia/manifest.json +++ b/resources/maps/bajacalifornia/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["north_america"], + "id": "BajaCalifornia", "map": { "height": 2120, "num_land_tiles": 1345295, @@ -14,6 +16,7 @@ "num_land_tiles": 331582, "width": 900 }, + "multiplayer_frequency": 4, "name": "Baja California", "nations": [ { @@ -56,5 +59,6 @@ "flag": "New_Mexico", "name": "New Mexico" } - ] + ], + "translation_key": "map.bajacalifornia" } diff --git a/resources/maps/balkans/manifest.json b/resources/maps/balkans/manifest.json index e8b5c4090..caaec41c4 100644 --- a/resources/maps/balkans/manifest.json +++ b/resources/maps/balkans/manifest.json @@ -196,6 +196,8 @@ "name": "Western Macedonia" } ], + "categories": ["europe"], + "id": "Balkans", "map": { "height": 2048, "num_land_tiles": 2478822, @@ -211,6 +213,7 @@ "num_land_tiles": 610636, "width": 1024 }, + "multiplayer_frequency": 6, "name": "Balkans", "nations": [ { @@ -328,5 +331,6 @@ "flag": "Sicily", "name": "Sicily" } - ] + ], + "translation_key": "map.balkans" } diff --git a/resources/maps/beringsea/manifest.json b/resources/maps/beringsea/manifest.json index 0f4fcf2a2..7a8d92388 100644 --- a/resources/maps/beringsea/manifest.json +++ b/resources/maps/beringsea/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["asia", "north_america"], + "id": "BeringSea", "map": { "height": 1600, "num_land_tiles": 1615723, @@ -14,6 +16,7 @@ "num_land_tiles": 396641, "width": 1250 }, + "multiplayer_frequency": 5, "name": "Bering Sea", "nations": [ { @@ -152,5 +155,6 @@ "y": 0 } ] - } + }, + "translation_key": "map.beringsea" } diff --git a/resources/maps/beringstrait/manifest.json b/resources/maps/beringstrait/manifest.json index 6213c1e1e..fafab00f8 100644 --- a/resources/maps/beringstrait/manifest.json +++ b/resources/maps/beringstrait/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["asia", "north_america"], + "id": "BeringStrait", "map": { "height": 916, "num_land_tiles": 596318, @@ -14,7 +16,8 @@ "num_land_tiles": 146676, "width": 750 }, - "name": "BeringStrait", + "multiplayer_frequency": 2, + "name": "Bering Strait", "nations": [ { "coordinates": [1297, 287], @@ -42,5 +45,6 @@ "y": 0 } ] - } + }, + "translation_key": "map.beringstrait" } diff --git a/resources/maps/betweentwoseas/manifest.json b/resources/maps/betweentwoseas/manifest.json index 13bdfec74..d6553dc23 100644 --- a/resources/maps/betweentwoseas/manifest.json +++ b/resources/maps/betweentwoseas/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe", "asia"], + "id": "BetweenTwoSeas", "map": { "height": 1060, "num_land_tiles": 1478803, @@ -14,7 +16,8 @@ "num_land_tiles": 364078, "width": 888 }, - "name": "BetweenTwoSeas", + "multiplayer_frequency": 5, + "name": "Between Two Seas", "nations": [ { "coordinates": [40, 674], @@ -91,5 +94,6 @@ "flag": "Circassia", "name": "Circassia" } - ] + ], + "translation_key": "map.betweentwoseas" } diff --git a/resources/maps/blacksea/manifest.json b/resources/maps/blacksea/manifest.json index 30295b97d..fe1581b68 100644 --- a/resources/maps/blacksea/manifest.json +++ b/resources/maps/blacksea/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe", "asia"], + "id": "BlackSea", "map": { "height": 1100, "num_land_tiles": 1165868, @@ -14,7 +16,8 @@ "num_land_tiles": 285772, "width": 750 }, - "name": "BlackSea", + "multiplayer_frequency": 6, + "name": "Black Sea", "nations": [ { "coordinates": [122, 647], @@ -61,5 +64,6 @@ "flag": "Circassia", "name": "Circassia" } - ] + ], + "translation_key": "map.blacksea" } diff --git a/resources/maps/bosphorusstraits/manifest.json b/resources/maps/bosphorusstraits/manifest.json index d3a3ce453..7ab9d8ce3 100644 --- a/resources/maps/bosphorusstraits/manifest.json +++ b/resources/maps/bosphorusstraits/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe", "asia"], + "id": "BosphorusStraits", "map": { "height": 612, "num_land_tiles": 382332, @@ -14,6 +16,7 @@ "num_land_tiles": 93711, "width": 500 }, + "multiplayer_frequency": 3, "name": "Bosphorus Straits", "nations": [ { @@ -142,5 +145,6 @@ "y": 0 } ] - } + }, + "translation_key": "map.bosphorusstraits" } diff --git a/resources/maps/britannia/manifest.json b/resources/maps/britannia/manifest.json index 237c80729..48659d87c 100644 --- a/resources/maps/britannia/manifest.json +++ b/resources/maps/britannia/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "Britannia", "map": { "height": 2088, "num_land_tiles": 1183898, @@ -14,6 +16,7 @@ "num_land_tiles": 290479, "width": 800 }, + "multiplayer_frequency": 5, "name": "Britannia", "nations": [ { @@ -115,5 +118,6 @@ "coordinates": [404, 1146], "name": "Fermanagh" } - ] + ], + "translation_key": "map.britannia" } diff --git a/resources/maps/britanniaclassic/manifest.json b/resources/maps/britanniaclassic/manifest.json index 255d8881b..eb71151c0 100644 --- a/resources/maps/britanniaclassic/manifest.json +++ b/resources/maps/britanniaclassic/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "BritanniaClassic", "map": { "height": 1396, "num_land_tiles": 933571, @@ -14,6 +16,7 @@ "num_land_tiles": 228703, "width": 1000 }, + "multiplayer_frequency": 0, "name": "Britannia Classic", "nations": [ { @@ -131,5 +134,6 @@ "flag": "1_Franks", "name": "Franks" } - ] + ], + "translation_key": "map.britanniaclassic" } diff --git a/resources/maps/caribbean/manifest.json b/resources/maps/caribbean/manifest.json index 8428839cb..af708fe5e 100644 --- a/resources/maps/caribbean/manifest.json +++ b/resources/maps/caribbean/manifest.json @@ -141,6 +141,8 @@ "name": "Tobago" } ], + "categories": ["north_america"], + "id": "Caribbean", "map": { "height": 1808, "num_land_tiles": 577573, @@ -156,6 +158,7 @@ "num_land_tiles": 138280, "width": 1600 }, + "multiplayer_frequency": 5, "name": "Caribbean", "nations": [ { @@ -328,5 +331,6 @@ "flag": "co", "name": "San Andres" } - ] + ], + "translation_key": "map.caribbean" } diff --git a/resources/maps/caucasus/manifest.json b/resources/maps/caucasus/manifest.json index ff8c8ff6b..52afb095c 100644 --- a/resources/maps/caucasus/manifest.json +++ b/resources/maps/caucasus/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe", "asia"], + "id": "Caucasus", "map": { "height": 1000, "num_land_tiles": 846140, @@ -14,6 +16,7 @@ "num_land_tiles": 209226, "width": 624 }, + "multiplayer_frequency": 5, "name": "Caucasus", "nations": [ { @@ -121,5 +124,6 @@ "flag": "tr", "name": "Eastern Anatolia" } - ] + ], + "translation_key": "map.caucasus" } diff --git a/resources/maps/choppingblock/manifest.json b/resources/maps/choppingblock/manifest.json index 4478c0b19..cfe81988a 100644 --- a/resources/maps/choppingblock/manifest.json +++ b/resources/maps/choppingblock/manifest.json @@ -142,6 +142,8 @@ "name": "Honeycomb" } ], + "categories": ["other"], + "id": "ChoppingBlock", "map": { "height": 1616, "num_land_tiles": 1485703, @@ -157,6 +159,7 @@ "num_land_tiles": 364395, "width": 808 }, + "multiplayer_frequency": 5, "name": "Chopping Block", "nations": [ { @@ -361,5 +364,6 @@ "y": 809 } ] - } + }, + "translation_key": "map.choppingblock" } diff --git a/resources/maps/conakry/manifest.json b/resources/maps/conakry/manifest.json index c90a9fc00..e661024cd 100644 --- a/resources/maps/conakry/manifest.json +++ b/resources/maps/conakry/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["africa"], + "id": "Conakry", "map": { "height": 1000, "num_land_tiles": 1108371, @@ -14,6 +16,7 @@ "num_land_tiles": 272605, "width": 1228 }, + "multiplayer_frequency": 3, "name": "Conakry", "nations": [ { @@ -132,5 +135,6 @@ "y": 0 } ] - } + }, + "translation_key": "map.conakry" } diff --git a/resources/maps/danishstraits/manifest.json b/resources/maps/danishstraits/manifest.json index 30d039b87..4e5b25503 100644 --- a/resources/maps/danishstraits/manifest.json +++ b/resources/maps/danishstraits/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "DanishStraits", "map": { "height": 1224, "num_land_tiles": 587312, @@ -14,6 +16,7 @@ "num_land_tiles": 142124, "width": 436 }, + "multiplayer_frequency": 5, "name": "Danish Straits", "nations": [ { @@ -146,5 +149,6 @@ "flag": "dk", "name": "Bornholm" } - ] + ], + "translation_key": "map.danishstraits" } diff --git a/resources/maps/deglaciatedantarctica/manifest.json b/resources/maps/deglaciatedantarctica/manifest.json index 8f426b849..f9b3ab350 100644 --- a/resources/maps/deglaciatedantarctica/manifest.json +++ b/resources/maps/deglaciatedantarctica/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["antarctica"], + "id": "DeglaciatedAntarctica", "map": { "height": 1840, "num_land_tiles": 1079790, @@ -14,6 +16,7 @@ "num_land_tiles": 261659, "width": 1150 }, + "multiplayer_frequency": 4, "name": "Deglaciated Antarctica", "nations": [ { @@ -61,5 +64,6 @@ "flag": "fr", "name": "French Claim" } - ] + ], + "translation_key": "map.deglaciatedantarctica" } diff --git a/resources/maps/didier/manifest.json b/resources/maps/didier/manifest.json index 77461228b..eb3f7f53b 100644 --- a/resources/maps/didier/manifest.json +++ b/resources/maps/didier/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["other"], + "id": "Didier", "map": { "height": 1348, "num_land_tiles": 1122321, @@ -14,6 +16,7 @@ "num_land_tiles": 278357, "width": 750 }, + "multiplayer_frequency": 1, "name": "Didier", "nations": [ { @@ -64,5 +67,6 @@ "coordinates": [622, 1220], "name": "Mell Confederation" } - ] + ], + "translation_key": "map.didier" } diff --git a/resources/maps/didierfrance/manifest.json b/resources/maps/didierfrance/manifest.json index dde5b1061..b476f6a1a 100644 --- a/resources/maps/didierfrance/manifest.json +++ b/resources/maps/didierfrance/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["other"], + "id": "DidierFrance", "map": { "height": 2248, "num_land_tiles": 2303633, @@ -14,7 +16,8 @@ "num_land_tiles": 571849, "width": 1050 }, - "name": "Didier (France)", + "multiplayer_frequency": 1, + "name": "Didier France", "nations": [ { "coordinates": [120, 680], @@ -222,5 +225,6 @@ "coordinates": [2012, 2198], "name": "Arryn" } - ] + ], + "translation_key": "map.didierfrance" } diff --git a/resources/maps/dyslexdria/manifest.json b/resources/maps/dyslexdria/manifest.json index 00cf416b4..ab9d9dc66 100644 --- a/resources/maps/dyslexdria/manifest.json +++ b/resources/maps/dyslexdria/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["world"], + "id": "Dyslexdria", "map": { "height": 1344, "num_land_tiles": 1893664, @@ -14,6 +16,7 @@ "num_land_tiles": 458342, "width": 1540 }, + "multiplayer_frequency": 8, "name": "Dyslexdria", "nations": [ { @@ -366,5 +369,6 @@ "flag": "Republic of Pirates", "name": "Biosphere Conmune" } - ] + ], + "translation_key": "map.dyslexdria" } diff --git a/resources/maps/eastasia/manifest.json b/resources/maps/eastasia/manifest.json index 807bc81f2..30f0954b0 100644 --- a/resources/maps/eastasia/manifest.json +++ b/resources/maps/eastasia/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["asia"], + "id": "EastAsia", "map": { "height": 1644, "num_land_tiles": 879264, @@ -14,6 +16,7 @@ "num_land_tiles": 214937, "width": 780 }, + "multiplayer_frequency": 5, "name": "East Asia", "nations": [ { @@ -126,5 +129,6 @@ "flag": "jp", "name": "Kinki" } - ] + ], + "translation_key": "map.eastasia" } diff --git a/resources/maps/europe/manifest.json b/resources/maps/europe/manifest.json index 5abcd38af..ce9f7077d 100644 --- a/resources/maps/europe/manifest.json +++ b/resources/maps/europe/manifest.json @@ -1,4 +1,7 @@ { + "categories": ["featured", "europe"], + "featured_rank": 2, + "id": "Europe", "map": { "height": 1672, "num_land_tiles": 2345907, @@ -14,6 +17,7 @@ "num_land_tiles": 568335, "width": 1452 }, + "multiplayer_frequency": 7, "name": "Europe", "nations": [ { @@ -276,5 +280,6 @@ "flag": "mc", "name": "Monaco" } - ] + ], + "translation_key": "map.europe" } diff --git a/resources/maps/europeclassic/manifest.json b/resources/maps/europeclassic/manifest.json index 57b2cf48d..2ad67d031 100644 --- a/resources/maps/europeclassic/manifest.json +++ b/resources/maps/europeclassic/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "EuropeClassic", "map": { "height": 1000, "num_land_tiles": 1008469, @@ -14,7 +16,8 @@ "num_land_tiles": 248492, "width": 1000 }, - "name": "Europe", + "multiplayer_frequency": 0, + "name": "Europe Classic", "nations": [ { "coordinates": [171, 171], @@ -201,5 +204,6 @@ "flag": "dk", "name": "Denmark" } - ] + ], + "translation_key": "map.europeclassic" } diff --git a/resources/maps/falklandislands/manifest.json b/resources/maps/falklandislands/manifest.json index 95aeb17a7..c01f7dc73 100644 --- a/resources/maps/falklandislands/manifest.json +++ b/resources/maps/falklandislands/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["south_america"], + "id": "FalklandIslands", "map": { "height": 1400, "num_land_tiles": 746474, @@ -14,6 +16,7 @@ "num_land_tiles": 178970, "width": 1050 }, + "multiplayer_frequency": 4, "name": "Falkland Islands", "nations": [ { @@ -92,5 +95,6 @@ "y": 0 } ] - } + }, + "translation_key": "map.falklandislands" } diff --git a/resources/maps/faroeislands/manifest.json b/resources/maps/faroeislands/manifest.json index 34e572f3f..5606b0cbd 100644 --- a/resources/maps/faroeislands/manifest.json +++ b/resources/maps/faroeislands/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "FaroeIslands", "map": { "height": 2000, "num_land_tiles": 424994, @@ -14,6 +16,7 @@ "num_land_tiles": 103090, "width": 800 }, + "multiplayer_frequency": 4, "name": "Faroe Islands", "nations": [ { @@ -46,5 +49,6 @@ "flag": "fo", "name": "Nordoyar Region" } - ] + ], + "translation_key": "map.faroeislands" } diff --git a/resources/maps/fourislands/manifest.json b/resources/maps/fourislands/manifest.json index 94e0196e2..be2d6fe4b 100644 --- a/resources/maps/fourislands/manifest.json +++ b/resources/maps/fourislands/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["other"], + "id": "FourIslands", "map": { "height": 1500, "num_land_tiles": 517044, @@ -14,6 +16,7 @@ "num_land_tiles": 127635, "width": 750 }, + "multiplayer_frequency": 4, "name": "Four Islands", "nations": [ { @@ -78,5 +81,6 @@ "y": 750 } ] - } + }, + "translation_key": "map.fourislands" } diff --git a/resources/maps/gatewaytotheatlantic/manifest.json b/resources/maps/gatewaytotheatlantic/manifest.json index b15d257ed..1553b3e42 100644 --- a/resources/maps/gatewaytotheatlantic/manifest.json +++ b/resources/maps/gatewaytotheatlantic/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "GatewayToTheAtlantic", "map": { "height": 1968, "num_land_tiles": 2239824, @@ -14,7 +16,8 @@ "num_land_tiles": 554984, "width": 1108 }, - "name": "GatewayToTheAtlantic", + "multiplayer_frequency": 5, + "name": "Gateway to the Atlantic", "nations": [ { "coordinates": [2161, 420], @@ -151,5 +154,6 @@ "flag": "Holy Roman Empire", "name": "Holy Roman Empire" } - ] + ], + "translation_key": "map.gatewaytotheatlantic" } diff --git a/resources/maps/giantworldmap/manifest.json b/resources/maps/giantworldmap/manifest.json index f6d08f47b..8a301c745 100644 --- a/resources/maps/giantworldmap/manifest.json +++ b/resources/maps/giantworldmap/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["world"], + "id": "GiantWorldMap", "map": { "height": 1948, "num_land_tiles": 2333974, @@ -14,7 +16,8 @@ "num_land_tiles": 563340, "width": 2054 }, - "name": "Giant_World_Map", + "multiplayer_frequency": 0, + "name": "Giant World Map", "nations": [ { "coordinates": [2309, 535], @@ -551,5 +554,6 @@ "flag": "northwestterritories", "name": "Northwest Territories" } - ] + ], + "translation_key": "map.giantworldmap" } diff --git a/resources/maps/greatlakes/manifest.json b/resources/maps/greatlakes/manifest.json index 8d846144d..be9839012 100644 --- a/resources/maps/greatlakes/manifest.json +++ b/resources/maps/greatlakes/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["north_america"], + "id": "GreatLakes", "map": { "height": 1300, "num_land_tiles": 1938066, @@ -14,6 +16,7 @@ "num_land_tiles": 476275, "width": 1000 }, + "multiplayer_frequency": 6, "name": "Great Lakes", "nations": [ { @@ -186,5 +189,6 @@ "flag": "ca", "name": "Rouyn-Noranda" } - ] + ], + "translation_key": "map.greatlakes" } diff --git a/resources/maps/gulfofstlawrence/manifest.json b/resources/maps/gulfofstlawrence/manifest.json index 91ed7f8a9..b6bca43c7 100644 --- a/resources/maps/gulfofstlawrence/manifest.json +++ b/resources/maps/gulfofstlawrence/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["north_america"], + "id": "GulfOfStLawrence", "map": { "height": 1348, "num_land_tiles": 874011, @@ -14,6 +16,7 @@ "num_land_tiles": 212526, "width": 810 }, + "multiplayer_frequency": 4, "name": "Gulf of St. Lawrence", "nations": [ { @@ -168,5 +171,6 @@ "y": 500 } ] - } + }, + "translation_key": "map.gulfofstlawrence" } diff --git a/resources/maps/halkidiki/manifest.json b/resources/maps/halkidiki/manifest.json index 93d09f526..bf8fc1362 100644 --- a/resources/maps/halkidiki/manifest.json +++ b/resources/maps/halkidiki/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "Halkidiki", "map": { "height": 1760, "num_land_tiles": 1728899, @@ -14,6 +16,7 @@ "num_land_tiles": 427883, "width": 1100 }, + "multiplayer_frequency": 4, "name": "Halkidiki", "nations": [ { @@ -56,5 +59,6 @@ "flag": "gr", "name": "Thrace" } - ] + ], + "translation_key": "map.halkidiki" } diff --git a/resources/maps/hawaii/manifest.json b/resources/maps/hawaii/manifest.json index 755a62f15..fc059491a 100644 --- a/resources/maps/hawaii/manifest.json +++ b/resources/maps/hawaii/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["north_america", "oceania"], + "id": "Hawaii", "map": { "height": 2076, "num_land_tiles": 408264, @@ -14,6 +16,7 @@ "num_land_tiles": 100951, "width": 1600 }, + "multiplayer_frequency": 4, "name": "Hawaii", "nations": [ { @@ -61,5 +64,6 @@ "flag": "us", "name": "Hilo" } - ] + ], + "translation_key": "map.hawaii" } diff --git a/resources/maps/hongkong/manifest.json b/resources/maps/hongkong/manifest.json index 3f2cc230d..56a1b7c34 100644 --- a/resources/maps/hongkong/manifest.json +++ b/resources/maps/hongkong/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["asia"], + "id": "HongKong", "map": { "height": 1996, "num_land_tiles": 2260689, @@ -14,6 +16,7 @@ "num_land_tiles": 557907, "width": 1390 }, + "multiplayer_frequency": 6, "name": "Hong Kong", "nations": [ { @@ -371,5 +374,6 @@ "flag": "hk", "name": "Tai Mo Shan" } - ] + ], + "translation_key": "map.hongkong" } diff --git a/resources/maps/iceland/manifest.json b/resources/maps/iceland/manifest.json index 43e44879d..208577645 100644 --- a/resources/maps/iceland/manifest.json +++ b/resources/maps/iceland/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "Iceland", "map": { "height": 1500, "num_land_tiles": 1069645, @@ -14,6 +16,7 @@ "num_land_tiles": 264736, "width": 1000 }, + "multiplayer_frequency": 4, "name": "Iceland", "nations": [ { @@ -56,5 +59,6 @@ "flag": "is", "name": "Eastern Region" } - ] + ], + "translation_key": "map.iceland" } diff --git a/resources/maps/indiansubcontinent/manifest.json b/resources/maps/indiansubcontinent/manifest.json index 3d2cf65d1..16cce6d3c 100644 --- a/resources/maps/indiansubcontinent/manifest.json +++ b/resources/maps/indiansubcontinent/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["asia"], + "id": "IndianSubcontinent", "map": { "height": 2220, "num_land_tiles": 2113509, @@ -14,6 +16,7 @@ "num_land_tiles": 519188, "width": 1000 }, + "multiplayer_frequency": 8, "name": "Indian Subcontinent", "nations": [ { @@ -276,5 +279,6 @@ "flag": "in", "name": "Puducherry" } - ] + ], + "translation_key": "map.indiansubcontinent" } diff --git a/resources/maps/italia/manifest.json b/resources/maps/italia/manifest.json index a79cdf735..469d7325a 100644 --- a/resources/maps/italia/manifest.json +++ b/resources/maps/italia/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "Italia", "map": { "height": 1272, "num_land_tiles": 775663, @@ -14,6 +16,7 @@ "num_land_tiles": 191249, "width": 680 }, + "multiplayer_frequency": 6, "name": "Italia", "nations": [ { @@ -70,5 +73,6 @@ "coordinates": [1238, 349], "name": "Ottoman Empire" } - ] + ], + "translation_key": "map.italia" } diff --git a/resources/maps/japan/manifest.json b/resources/maps/japan/manifest.json index 835f905eb..5ad646270 100644 --- a/resources/maps/japan/manifest.json +++ b/resources/maps/japan/manifest.json @@ -1,4 +1,7 @@ { + "categories": ["featured", "asia"], + "featured_rank": 7, + "id": "Japan", "map": { "height": 2500, "num_land_tiles": 478894, @@ -14,7 +17,8 @@ "num_land_tiles": 116922, "width": 1250 }, - "name": "japan", + "multiplayer_frequency": 6, + "name": "Japan", "nations": [ { "coordinates": [1895, 288], @@ -76,5 +80,6 @@ "flag": "jp", "name": "Kyoto" } - ] + ], + "translation_key": "map.japan" } diff --git a/resources/maps/juandefucastrait/manifest.json b/resources/maps/juandefucastrait/manifest.json index a5b3f5956..c864b97d4 100644 --- a/resources/maps/juandefucastrait/manifest.json +++ b/resources/maps/juandefucastrait/manifest.json @@ -221,6 +221,8 @@ "name": "Sudden Valley" } ], + "categories": ["north_america"], + "id": "JuanDeFucaStrait", "map": { "height": 1100, "num_land_tiles": 1666141, @@ -236,6 +238,7 @@ "num_land_tiles": 410851, "width": 1500 }, + "multiplayer_frequency": 4, "name": "Juan De Fuca Strait", "nations": [ { @@ -340,5 +343,6 @@ "y": 0 } ] - } + }, + "translation_key": "map.juandefucastrait" } diff --git a/resources/maps/korea/manifest.json b/resources/maps/korea/manifest.json index 4e2627f18..007bd5a50 100644 --- a/resources/maps/korea/manifest.json +++ b/resources/maps/korea/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["asia"], + "id": "Korea", "map": { "height": 2148, "num_land_tiles": 1193914, @@ -14,6 +16,7 @@ "num_land_tiles": 294064, "width": 546 }, + "multiplayer_frequency": 5, "name": "Korea", "nations": [ { @@ -191,5 +194,6 @@ "flag": "jp", "name": "Saga" } - ] + ], + "translation_key": "map.korea" } diff --git a/resources/maps/labyrinth/manifest.json b/resources/maps/labyrinth/manifest.json index 428a6372a..c624eb6a9 100644 --- a/resources/maps/labyrinth/manifest.json +++ b/resources/maps/labyrinth/manifest.json @@ -226,6 +226,8 @@ "name": "Zapopan" } ], + "categories": ["other"], + "id": "Labyrinth", "map": { "height": 1360, "num_land_tiles": 1524448, @@ -241,6 +243,7 @@ "num_land_tiles": 372162, "width": 680 }, + "multiplayer_frequency": 6, "name": "Labyrinth", "nations": [ { @@ -549,5 +552,6 @@ "y": 920 } ] - } + }, + "translation_key": "map.labyrinth" } diff --git a/resources/maps/lemnos/manifest.json b/resources/maps/lemnos/manifest.json index 793c62d13..2c3c75601 100644 --- a/resources/maps/lemnos/manifest.json +++ b/resources/maps/lemnos/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "Lemnos", "map": { "height": 1420, "num_land_tiles": 874763, @@ -14,6 +16,7 @@ "num_land_tiles": 216496, "width": 874 }, + "multiplayer_frequency": 3, "name": "Lemnos", "nations": [ { @@ -61,5 +64,6 @@ "flag": "gr", "name": "Pyrgos" } - ] + ], + "translation_key": "map.lemnos" } diff --git a/resources/maps/lisbon/manifest.json b/resources/maps/lisbon/manifest.json index 1ac32a349..a28c82a10 100644 --- a/resources/maps/lisbon/manifest.json +++ b/resources/maps/lisbon/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "Lisbon", "map": { "height": 1600, "num_land_tiles": 1495857, @@ -14,6 +16,7 @@ "num_land_tiles": 369114, "width": 800 }, + "multiplayer_frequency": 4, "name": "Lisbon", "nations": [ { @@ -91,5 +94,6 @@ "flag": "pt", "name": "Carvalhal" } - ] + ], + "translation_key": "map.lisbon" } diff --git a/resources/maps/losangeles/manifest.json b/resources/maps/losangeles/manifest.json index 54aafc1b3..2236d26c1 100644 --- a/resources/maps/losangeles/manifest.json +++ b/resources/maps/losangeles/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["north_america"], + "id": "LosAngeles", "map": { "height": 2276, "num_land_tiles": 2066156, @@ -14,6 +16,7 @@ "num_land_tiles": 508420, "width": 900 }, + "multiplayer_frequency": 8, "name": "Los Angeles", "nations": [ { @@ -146,5 +149,6 @@ "flag": "California", "name": "Encino" } - ] + ], + "translation_key": "map.losangeles" } diff --git a/resources/maps/luna/manifest.json b/resources/maps/luna/manifest.json index 47d7f263e..ed5603e29 100644 --- a/resources/maps/luna/manifest.json +++ b/resources/maps/luna/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["cosmic"], + "id": "Luna", "map": { "height": 3508, "num_land_tiles": 1517614, @@ -14,6 +16,7 @@ "num_land_tiles": 363006, "width": 654 }, + "multiplayer_frequency": 6, "name": "Luna", "nations": [ { @@ -157,5 +160,6 @@ "y": 1754 } ] - } + }, + "translation_key": "map.luna" } diff --git a/resources/maps/manicouagan/manifest.json b/resources/maps/manicouagan/manifest.json index fd1a2e919..8a49d8bcd 100644 --- a/resources/maps/manicouagan/manifest.json +++ b/resources/maps/manicouagan/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["north_america"], + "id": "Manicouagan", "map": { "height": 1600, "num_land_tiles": 1992029, @@ -14,6 +16,7 @@ "num_land_tiles": 489928, "width": 800 }, + "multiplayer_frequency": 4, "name": "Manicouagan", "nations": [ { @@ -71,5 +74,6 @@ "flag": "Quebec", "name": "Lamontagne" } - ] + ], + "translation_key": "map.manicouagan" } diff --git a/resources/maps/marenostrum/manifest.json b/resources/maps/marenostrum/manifest.json index a05e9fc8a..60d7aaafb 100644 --- a/resources/maps/marenostrum/manifest.json +++ b/resources/maps/marenostrum/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "MareNostrum", "map": { "height": 1448, "num_land_tiles": 2644620, @@ -14,6 +16,7 @@ "num_land_tiles": 652112, "width": 1424 }, + "multiplayer_frequency": 6, "name": "Mare Nostrum", "nations": [ { @@ -206,5 +209,6 @@ "flag": "Amazigh flag", "name": "Numidia" } - ] + ], + "translation_key": "map.marenostrum" } diff --git a/resources/maps/mars/manifest.json b/resources/maps/mars/manifest.json index 6f1ab8858..6804721bf 100644 --- a/resources/maps/mars/manifest.json +++ b/resources/maps/mars/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["cosmic"], + "id": "Mars", "map": { "height": 1000, "num_land_tiles": 1354047, @@ -14,6 +16,7 @@ "num_land_tiles": 335749, "width": 1000 }, + "multiplayer_frequency": 3, "name": "Mars", "nations": [ { @@ -46,5 +49,6 @@ "flag": "cn", "name": "China" } - ] + ], + "translation_key": "map.mars" } diff --git a/resources/maps/mena/manifest.json b/resources/maps/mena/manifest.json index f6e30aa92..53f1c7d56 100644 --- a/resources/maps/mena/manifest.json +++ b/resources/maps/mena/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["asia", "africa"], + "id": "Mena", "map": { "height": 964, "num_land_tiles": 1621317, @@ -14,7 +16,8 @@ "num_land_tiles": 400304, "width": 1100 }, - "name": "MENA", + "multiplayer_frequency": 6, + "name": "Mena", "nations": [ { "coordinates": [257, 82], @@ -191,5 +194,6 @@ "flag": "kz", "name": "Kazakhstan" } - ] + ], + "translation_key": "map.mena" } diff --git a/resources/maps/middleeast/manifest.json b/resources/maps/middleeast/manifest.json index 5eddf3aa5..f75cd71f2 100644 --- a/resources/maps/middleeast/manifest.json +++ b/resources/maps/middleeast/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["asia"], + "id": "MiddleEast", "map": { "height": 2060, "num_land_tiles": 3449078, @@ -14,6 +16,7 @@ "num_land_tiles": 856603, "width": 1100 }, + "multiplayer_frequency": 8, "name": "Middle East", "nations": [ { @@ -151,5 +154,6 @@ "flag": "ru", "name": "Russian State" } - ] + ], + "translation_key": "map.middleeast" } diff --git a/resources/maps/milkyway/manifest.json b/resources/maps/milkyway/manifest.json index 42b0909b6..e62dbd445 100644 --- a/resources/maps/milkyway/manifest.json +++ b/resources/maps/milkyway/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["cosmic"], + "id": "MilkyWay", "map": { "height": 1500, "num_land_tiles": 442979, @@ -14,7 +16,8 @@ "num_land_tiles": 105978, "width": 750 }, - "name": "Milky Way", + "multiplayer_frequency": 8, + "name": "MilkyWay", "nations": [ { "coordinates": [775, 757], @@ -46,5 +49,6 @@ "flag": "Cthulhu Republic", "name": "The Void" } - ] + ], + "translation_key": "map.milkyway" } diff --git a/resources/maps/mississippiriver/manifest.json b/resources/maps/mississippiriver/manifest.json index fb2e9ea2e..7cf9b41ef 100644 --- a/resources/maps/mississippiriver/manifest.json +++ b/resources/maps/mississippiriver/manifest.json @@ -256,6 +256,8 @@ "name": "Round Lake" } ], + "categories": ["north_america"], + "id": "MississippiRiver", "map": { "height": 4200, "num_land_tiles": 1499924, @@ -271,6 +273,7 @@ "num_land_tiles": 369917, "width": 200 }, + "multiplayer_frequency": 3, "name": "Mississippi River", "nations": [ { @@ -328,5 +331,6 @@ "flag": "Arkansas", "name": "West Memphis" } - ] + ], + "translation_key": "map.mississippiriver" } diff --git a/resources/maps/montreal/manifest.json b/resources/maps/montreal/manifest.json index 94b5379b0..15d1f2b4e 100644 --- a/resources/maps/montreal/manifest.json +++ b/resources/maps/montreal/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["north_america"], + "id": "Montreal", "map": { "height": 1500, "num_land_tiles": 1954940, @@ -14,6 +16,7 @@ "num_land_tiles": 483571, "width": 764 }, + "multiplayer_frequency": 6, "name": "Montreal", "nations": [ { @@ -76,5 +79,6 @@ "flag": "Quebec", "name": "Pointe-aux-Trembles" } - ] + ], + "translation_key": "map.montreal" } diff --git a/resources/maps/newyorkcity/manifest.json b/resources/maps/newyorkcity/manifest.json index eee0857f7..8bcb84130 100644 --- a/resources/maps/newyorkcity/manifest.json +++ b/resources/maps/newyorkcity/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["north_america"], + "id": "NewYorkCity", "map": { "height": 1900, "num_land_tiles": 1648646, @@ -14,6 +16,7 @@ "num_land_tiles": 406215, "width": 750 }, + "multiplayer_frequency": 3, "name": "New York City", "nations": [ { @@ -105,5 +108,6 @@ "flag": "gb-eng", "name": "Gravesend" } - ] + ], + "translation_key": "map.newyorkcity" } diff --git a/resources/maps/niledelta/manifest.json b/resources/maps/niledelta/manifest.json index 5607bf1d5..34c2eacf7 100644 --- a/resources/maps/niledelta/manifest.json +++ b/resources/maps/niledelta/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["africa"], + "id": "NileDelta", "map": { "height": 1280, "num_land_tiles": 1363238, @@ -14,6 +16,7 @@ "num_land_tiles": 336925, "width": 778 }, + "multiplayer_frequency": 4, "name": "Nile Delta", "nations": [ { @@ -71,5 +74,6 @@ "flag": "eg", "name": "El Mansoura" } - ] + ], + "translation_key": "map.niledelta" } diff --git a/resources/maps/northamerica/manifest.json b/resources/maps/northamerica/manifest.json index 50add13c8..7404a4dcd 100644 --- a/resources/maps/northamerica/manifest.json +++ b/resources/maps/northamerica/manifest.json @@ -1,4 +1,7 @@ { + "categories": ["featured", "north_america"], + "featured_rank": 3, + "id": "NorthAmerica", "map": { "height": 1448, "num_land_tiles": 1243623, @@ -14,7 +17,8 @@ "num_land_tiles": 294494, "width": 1400 }, - "name": "NorthAmerica", + "multiplayer_frequency": 5, + "name": "North America", "nations": [ { "coordinates": [1625, 1040], @@ -361,5 +365,6 @@ "flag": "Massachusetts", "name": "Massachusetts" } - ] + ], + "translation_key": "map.northamerica" } diff --git a/resources/maps/northwestpassage/manifest.json b/resources/maps/northwestpassage/manifest.json index 01dbc33c5..84a034256 100644 --- a/resources/maps/northwestpassage/manifest.json +++ b/resources/maps/northwestpassage/manifest.json @@ -196,6 +196,8 @@ "name": "Zackenberg" } ], + "categories": ["north_america"], + "id": "NorthwestPassage", "map": { "height": 1664, "num_land_tiles": 1569905, @@ -211,6 +213,7 @@ "num_land_tiles": 379907, "width": 1250 }, + "multiplayer_frequency": 5, "name": "Northwest Passage", "nations": [ { @@ -318,5 +321,6 @@ "flag": "northwestterritories", "name": "Inuvik" } - ] + ], + "translation_key": "map.northwestpassage" } diff --git a/resources/maps/oceania/manifest.json b/resources/maps/oceania/manifest.json index 07ca517d4..0159d53ba 100644 --- a/resources/maps/oceania/manifest.json +++ b/resources/maps/oceania/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["oceania"], + "id": "Oceania", "map": { "height": 1000, "num_land_tiles": 194648, @@ -14,6 +16,7 @@ "num_land_tiles": 46259, "width": 1000 }, + "multiplayer_frequency": 0, "name": "Oceania", "nations": [ { @@ -126,5 +129,6 @@ "flag": "Hawaii", "name": "Hawaii" } - ] + ], + "translation_key": "map.oceania" } diff --git a/resources/maps/onion/manifest.json b/resources/maps/onion/manifest.json index e603b8465..d25d1e56a 100644 --- a/resources/maps/onion/manifest.json +++ b/resources/maps/onion/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["other"], + "id": "Onion", "map": { "height": 512, "num_land_tiles": 210555, @@ -14,7 +16,8 @@ "num_land_tiles": 51713, "width": 256 }, - "name": "onion", + "multiplayer_frequency": 2, + "name": "Onion", "nations": [ { "coordinates": [51, 188], @@ -31,5 +34,6 @@ "flag": "", "name": "Inner Tribe" } - ] + ], + "translation_key": "map.onion" } diff --git a/resources/maps/pangaea/manifest.json b/resources/maps/pangaea/manifest.json index 21e339d2e..f642ed4e7 100644 --- a/resources/maps/pangaea/manifest.json +++ b/resources/maps/pangaea/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["other"], + "id": "Pangaea", "map": { "height": 1000, "num_land_tiles": 420335, @@ -14,6 +16,7 @@ "num_land_tiles": 102211, "width": 500 }, + "multiplayer_frequency": 5, "name": "Pangaea", "nations": [ { @@ -161,5 +164,6 @@ "flag": "gb", "name": "United Kingdom" } - ] + ], + "translation_key": "map.pangaea" } diff --git a/resources/maps/passage/manifest.json b/resources/maps/passage/manifest.json index dafaf63f4..21ecc5983 100644 --- a/resources/maps/passage/manifest.json +++ b/resources/maps/passage/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["other"], + "id": "Passage", "map": { "height": 400, "num_land_tiles": 803994, @@ -14,6 +16,7 @@ "num_land_tiles": 195716, "width": 3000 }, + "multiplayer_frequency": 4, "name": "Passage", "nations": [ { @@ -80,5 +83,6 @@ "coordinates": [5906, 364], "name": "Eastos" } - ] + ], + "translation_key": "map.passage" } diff --git a/resources/maps/pluto/manifest.json b/resources/maps/pluto/manifest.json index e6033022d..a982f626c 100644 --- a/resources/maps/pluto/manifest.json +++ b/resources/maps/pluto/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["cosmic"], + "id": "Pluto", "map": { "height": 1300, "num_land_tiles": 1987279, @@ -14,6 +16,7 @@ "num_land_tiles": 489070, "width": 1050 }, + "multiplayer_frequency": 6, "name": "Pluto", "nations": [ { @@ -112,5 +115,6 @@ "y": 0 } ] - } + }, + "translation_key": "map.pluto" } diff --git a/resources/maps/sanfrancisco/manifest.json b/resources/maps/sanfrancisco/manifest.json index 34f308bba..47853ccce 100644 --- a/resources/maps/sanfrancisco/manifest.json +++ b/resources/maps/sanfrancisco/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["north_america"], + "id": "SanFrancisco", "map": { "height": 1700, "num_land_tiles": 1887961, @@ -14,7 +16,8 @@ "num_land_tiles": 464870, "width": 1000 }, - "name": "SanFrancisco", + "multiplayer_frequency": 3, + "name": "San Francisco", "nations": [ { "coordinates": [996, 990], @@ -121,5 +124,6 @@ "flag": "California", "name": "Bodega Bay" } - ] + ], + "translation_key": "map.sanfrancisco" } diff --git a/resources/maps/sierpinski/manifest.json b/resources/maps/sierpinski/manifest.json index 06eb48015..de1bb903e 100644 --- a/resources/maps/sierpinski/manifest.json +++ b/resources/maps/sierpinski/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["other"], + "id": "Sierpinski", "map": { "height": 1400, "num_land_tiles": 582988, @@ -14,6 +16,7 @@ "num_land_tiles": 143268, "width": 700 }, + "multiplayer_frequency": 10, "name": "Sierpinski", "nations": [ { @@ -61,5 +64,6 @@ "flag": "", "name": "Center" } - ] + ], + "translation_key": "map.sierpinski" } diff --git a/resources/maps/southamerica/manifest.json b/resources/maps/southamerica/manifest.json index f83ace1e3..be082731f 100644 --- a/resources/maps/southamerica/manifest.json +++ b/resources/maps/southamerica/manifest.json @@ -1,4 +1,7 @@ { + "categories": ["featured", "south_america"], + "featured_rank": 4, + "id": "SouthAmerica", "map": { "height": 2376, "num_land_tiles": 1411064, @@ -14,6 +17,7 @@ "num_land_tiles": 342275, "width": 872 }, + "multiplayer_frequency": 5, "name": "South America", "nations": [ { @@ -141,5 +145,6 @@ "flag": "Sao Paulo", "name": "São Paulo" } - ] + ], + "translation_key": "map.southamerica" } diff --git a/resources/maps/southeastasia/manifest.json b/resources/maps/southeastasia/manifest.json index bfa9d00c1..08c5cb92d 100644 --- a/resources/maps/southeastasia/manifest.json +++ b/resources/maps/southeastasia/manifest.json @@ -156,6 +156,8 @@ "name": "Paracel Islands" } ], + "categories": ["asia"], + "id": "SoutheastAsia", "map": { "height": 1672, "num_land_tiles": 977094, @@ -171,7 +173,8 @@ "num_land_tiles": 235008, "width": 1406 }, - "name": "Southeast Asia", + "multiplayer_frequency": 5, + "name": "SoutheastAsia", "nations": [ { "coordinates": [1319, 76], @@ -328,5 +331,6 @@ "flag": "Wa State", "name": "Wa State" } - ] + ], + "translation_key": "map.southeastasia" } diff --git a/resources/maps/straitofgibraltar/manifest.json b/resources/maps/straitofgibraltar/manifest.json index 569973063..4c4dcf343 100644 --- a/resources/maps/straitofgibraltar/manifest.json +++ b/resources/maps/straitofgibraltar/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe", "africa"], + "id": "StraitOfGibraltar", "map": { "height": 1476, "num_land_tiles": 1957694, @@ -14,6 +16,7 @@ "num_land_tiles": 486917, "width": 1450 }, + "multiplayer_frequency": 5, "name": "Strait of Gibraltar", "nations": [ { @@ -64,5 +67,6 @@ "y": 651 } ] - } + }, + "translation_key": "map.straitofgibraltar" } diff --git a/resources/maps/straitofhormuz/manifest.json b/resources/maps/straitofhormuz/manifest.json index 406956896..3071261f4 100644 --- a/resources/maps/straitofhormuz/manifest.json +++ b/resources/maps/straitofhormuz/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["asia"], + "id": "StraitOfHormuz", "map": { "height": 1200, "num_land_tiles": 1255327, @@ -14,6 +16,7 @@ "num_land_tiles": 312041, "width": 900 }, + "multiplayer_frequency": 4, "name": "Strait of Hormuz", "nations": [ { @@ -137,5 +140,6 @@ "y": 0 } ] - } + }, + "translation_key": "map.straitofhormuz" } diff --git a/resources/maps/straitofmalacca/manifest.json b/resources/maps/straitofmalacca/manifest.json index de05fcc59..fde4e6670 100644 --- a/resources/maps/straitofmalacca/manifest.json +++ b/resources/maps/straitofmalacca/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["asia"], + "id": "StraitOfMalacca", "map": { "height": 1644, "num_land_tiles": 865820, @@ -14,6 +16,7 @@ "num_land_tiles": 211494, "width": 916 }, + "multiplayer_frequency": 4, "name": "Strait Of Malacca", "nations": [ { @@ -81,5 +84,6 @@ "flag": "id", "name": "Riau Islands" } - ] + ], + "translation_key": "map.straitofmalacca" } diff --git a/resources/maps/surrounded/manifest.json b/resources/maps/surrounded/manifest.json index 45b34a4d1..20cb4f9af 100644 --- a/resources/maps/surrounded/manifest.json +++ b/resources/maps/surrounded/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["other"], + "id": "Surrounded", "map": { "height": 1976, "num_land_tiles": 767607, @@ -14,6 +16,7 @@ "num_land_tiles": 188986, "width": 988 }, + "multiplayer_frequency": 4, "name": "Surrounded", "nations": [ { @@ -98,5 +101,6 @@ "y": 988 } ] - } + }, + "translation_key": "map.surrounded" } diff --git a/resources/maps/svalmel/manifest.json b/resources/maps/svalmel/manifest.json index fb3b03542..1acccb55b 100644 --- a/resources/maps/svalmel/manifest.json +++ b/resources/maps/svalmel/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["other"], + "id": "Svalmel", "map": { "height": 1580, "num_land_tiles": 1011623, @@ -14,6 +16,7 @@ "num_land_tiles": 248032, "width": 850 }, + "multiplayer_frequency": 8, "name": "Svalmel", "nations": [ { @@ -41,5 +44,6 @@ "flag": "no", "name": "Nordaustlandet" } - ] + ], + "translation_key": "map.svalmel" } diff --git a/resources/maps/taiwanstrait/manifest.json b/resources/maps/taiwanstrait/manifest.json index 67bc4b132..b4f4d2569 100644 --- a/resources/maps/taiwanstrait/manifest.json +++ b/resources/maps/taiwanstrait/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["asia"], + "id": "TaiwanStrait", "map": { "height": 1600, "num_land_tiles": 907469, @@ -14,6 +16,7 @@ "num_land_tiles": 224367, "width": 800 }, + "multiplayer_frequency": 5, "name": "Taiwan Strait", "nations": [ { @@ -157,5 +160,6 @@ "y": 0 } ] - } + }, + "translation_key": "map.taiwanstrait" } diff --git a/resources/maps/thebox/manifest.json b/resources/maps/thebox/manifest.json index 0a63b7e4e..2f56ac911 100644 --- a/resources/maps/thebox/manifest.json +++ b/resources/maps/thebox/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["other"], + "id": "TheBox", "map": { "height": 2048, "num_land_tiles": 4194304, @@ -14,7 +16,8 @@ "num_land_tiles": 1048576, "width": 1024 }, - "name": "TheBox", + "multiplayer_frequency": 3, + "name": "The Box", "nations": [ { "coordinates": [10, 10], @@ -81,5 +84,6 @@ "flag": "", "name": "Non-peaceful Bot" } - ] + ], + "translation_key": "map.thebox" } diff --git a/resources/maps/titan/manifest.json b/resources/maps/titan/manifest.json index 949812953..07a67af5c 100644 --- a/resources/maps/titan/manifest.json +++ b/resources/maps/titan/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["cosmic"], + "id": "Titan", "map": { "height": 2160, "num_land_tiles": 1627144, @@ -14,6 +16,7 @@ "num_land_tiles": 398688, "width": 616 }, + "multiplayer_frequency": 3, "name": "Titan", "nations": [ { @@ -128,5 +131,6 @@ "flag": "un", "name": "UNOOSA" } - ] + ], + "translation_key": "map.titan" } diff --git a/resources/maps/tourney1/manifest.json b/resources/maps/tourney1/manifest.json index 2c417aaee..4ee6c8f22 100644 --- a/resources/maps/tourney1/manifest.json +++ b/resources/maps/tourney1/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["tournament"], + "id": "Tourney1", "map": { "height": 1500, "num_land_tiles": 984577, @@ -14,7 +16,8 @@ "num_land_tiles": 244567, "width": 750 }, - "name": "Tourney1", + "multiplayer_frequency": 0, + "name": "Tourney 2 Teams", "nations": [ { "coordinates": [177, 510], @@ -24,5 +27,6 @@ "coordinates": [847, 511], "name": "Right" } - ] + ], + "translation_key": "map.tourney1" } diff --git a/resources/maps/tourney2/manifest.json b/resources/maps/tourney2/manifest.json index 8c455b622..7b45be337 100644 --- a/resources/maps/tourney2/manifest.json +++ b/resources/maps/tourney2/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["tournament"], + "id": "Tourney2", "map": { "height": 1500, "num_land_tiles": 1024327, @@ -14,7 +16,8 @@ "num_land_tiles": 254300, "width": 750 }, - "name": "Tourney2", + "multiplayer_frequency": 0, + "name": "Tourney 3 Teams", "nations": [ { "coordinates": [339, 987], @@ -28,5 +31,6 @@ "coordinates": [750, 278], "name": "North" } - ] + ], + "translation_key": "map.tourney2" } diff --git a/resources/maps/tourney3/manifest.json b/resources/maps/tourney3/manifest.json index 58dff4a4d..8cc2fa1bb 100644 --- a/resources/maps/tourney3/manifest.json +++ b/resources/maps/tourney3/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["tournament"], + "id": "Tourney3", "map": { "height": 1500, "num_land_tiles": 1008007, @@ -14,7 +16,8 @@ "num_land_tiles": 250191, "width": 750 }, - "name": "Tourney3", + "multiplayer_frequency": 0, + "name": "Tourney 4 Teams", "nations": [ { "coordinates": [437, 410], @@ -32,5 +35,6 @@ "coordinates": [1068, 1075], "name": "South East" } - ] + ], + "translation_key": "map.tourney3" } diff --git a/resources/maps/tourney4/manifest.json b/resources/maps/tourney4/manifest.json index b11e1caf2..a9c59ba75 100644 --- a/resources/maps/tourney4/manifest.json +++ b/resources/maps/tourney4/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["tournament"], + "id": "Tourney4", "map": { "height": 1500, "num_land_tiles": 905705, @@ -14,7 +16,8 @@ "num_land_tiles": 224342, "width": 750 }, - "name": "Tourney4", + "multiplayer_frequency": 0, + "name": "Tourney 8 Teams", "nations": [ { "coordinates": [568, 309], @@ -48,5 +51,6 @@ "coordinates": [315, 927], "name": "West South West" } - ] + ], + "translation_key": "map.tourney4" } diff --git a/resources/maps/tradersdream/manifest.json b/resources/maps/tradersdream/manifest.json index 0f82a12a2..34f9cd13e 100644 --- a/resources/maps/tradersdream/manifest.json +++ b/resources/maps/tradersdream/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["other"], + "id": "TradersDream", "map": { "height": 1920, "num_land_tiles": 972041, @@ -14,6 +16,7 @@ "num_land_tiles": 240669, "width": 1100 }, + "multiplayer_frequency": 4, "name": "Traders Dream", "nations": [ { @@ -97,5 +100,6 @@ "y": 960 } ] - } + }, + "translation_key": "map.tradersdream" } diff --git a/resources/maps/twolakes/manifest.json b/resources/maps/twolakes/manifest.json index 86ab4c670..49aa36ac4 100644 --- a/resources/maps/twolakes/manifest.json +++ b/resources/maps/twolakes/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "TwoLakes", "map": { "height": 1840, "num_land_tiles": 3423870, @@ -14,6 +16,7 @@ "num_land_tiles": 852792, "width": 1050 }, + "multiplayer_frequency": 6, "name": "Two Lakes", "nations": [ { @@ -41,5 +44,6 @@ "flag": "gr", "name": "Prespa" } - ] + ], + "translation_key": "map.twolakes" } diff --git a/resources/maps/venice/manifest.json b/resources/maps/venice/manifest.json index 560250c52..7a9151965 100644 --- a/resources/maps/venice/manifest.json +++ b/resources/maps/venice/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["europe"], + "id": "Venice", "map": { "height": 1500, "num_land_tiles": 823860, @@ -14,6 +16,7 @@ "num_land_tiles": 198423, "width": 1000 }, + "multiplayer_frequency": 6, "name": "Venice", "nations": [ { @@ -91,5 +94,6 @@ "flag": "venice", "name": "Sant'Elena" } - ] + ], + "translation_key": "map.venice" } diff --git a/resources/maps/world/manifest.json b/resources/maps/world/manifest.json index 77a2fd282..85887f381 100644 --- a/resources/maps/world/manifest.json +++ b/resources/maps/world/manifest.json @@ -1,4 +1,7 @@ { + "categories": ["featured", "world"], + "featured_rank": 1, + "id": "World", "map": { "height": 1000, "num_land_tiles": 651609, @@ -14,6 +17,7 @@ "num_land_tiles": 158086, "width": 1000 }, + "multiplayer_frequency": 20, "name": "World", "nations": [ { @@ -376,5 +380,6 @@ "flag": "lk", "name": "Sri Lanka" } - ] + ], + "translation_key": "map.world" } diff --git a/resources/maps/worldinverted/manifest.json b/resources/maps/worldinverted/manifest.json index c60afac92..8f9706e30 100644 --- a/resources/maps/worldinverted/manifest.json +++ b/resources/maps/worldinverted/manifest.json @@ -951,6 +951,8 @@ "name": "Reykjanes Delta" } ], + "categories": ["world"], + "id": "WorldInverted", "map": { "height": 1248, "num_land_tiles": 1561762, @@ -966,6 +968,7 @@ "num_land_tiles": 381499, "width": 1250 }, + "multiplayer_frequency": 8, "name": "World Inverted", "nations": [ { @@ -1426,5 +1429,6 @@ "flag": "", "name": "Emerald" } - ] + ], + "translation_key": "map.worldinverted" } diff --git a/resources/maps/yellowsea/manifest.json b/resources/maps/yellowsea/manifest.json index 5a1f8df17..2adb15451 100644 --- a/resources/maps/yellowsea/manifest.json +++ b/resources/maps/yellowsea/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["asia"], + "id": "YellowSea", "map": { "height": 1152, "num_land_tiles": 1042745, @@ -14,6 +16,7 @@ "num_land_tiles": 258545, "width": 750 }, + "multiplayer_frequency": 5, "name": "Yellow Sea", "nations": [ { @@ -56,5 +59,6 @@ "flag": "cn", "name": "Jilin" } - ] + ], + "translation_key": "map.yellowsea" } diff --git a/resources/maps/yenisei/manifest.json b/resources/maps/yenisei/manifest.json index 683d47b59..a9502dc53 100644 --- a/resources/maps/yenisei/manifest.json +++ b/resources/maps/yenisei/manifest.json @@ -1,4 +1,6 @@ { + "categories": ["asia"], + "id": "Yenisei", "map": { "height": 1500, "num_land_tiles": 1207315, @@ -14,6 +16,7 @@ "num_land_tiles": 294828, "width": 600 }, + "multiplayer_frequency": 6, "name": "Yenisei", "nations": [ { @@ -46,5 +49,6 @@ "flag": "ru", "name": "Northern Island" } - ] + ], + "translation_key": "map.yenisei" } diff --git a/src/client/Utils.ts b/src/client/Utils.ts index 3a1300356..d71538c59 100644 --- a/src/client/Utils.ts +++ b/src/client/Utils.ts @@ -1,8 +1,10 @@ import IntlMessageFormat from "intl-messageformat"; import { Duos, + GameMapType, GameMode, HumansVsNations, + mapTranslationKeys, MessageType, PublicGameModifiers, Quads, @@ -21,7 +23,10 @@ export function normaliseMapKey(mapName: string): string { export function getMapName(mapName: string | undefined): string | null { if (!mapName) return null; - return translateText(`map.${normaliseMapKey(mapName)}`); + const translationKey = + mapTranslationKeys[mapName as GameMapType] ?? + `map.${normaliseMapKey(mapName)}`; + return translateText(translationKey); } /** diff --git a/src/client/components/map/MapDisplay.ts b/src/client/components/map/MapDisplay.ts index e600ca531..4faf79228 100644 --- a/src/client/components/map/MapDisplay.ts +++ b/src/client/components/map/MapDisplay.ts @@ -49,6 +49,20 @@ export class MapDisplay extends LitElement { super.disconnectedCallback(); } + updated(changedProperties: Map) { + // If this element is reused for a different map, reload its data — + // otherwise it keeps showing the previous map's thumbnail. + const previousMapKey = changedProperties.get("mapKey"); + if ( + changedProperties.has("mapKey") && + previousMapKey !== undefined && + previousMapKey !== this.mapKey && + this.dataLoaded + ) { + this.loadMapData(); + } + } + private async loadMapData() { if (!this.mapKey) return; diff --git a/src/client/components/map/MapPicker.ts b/src/client/components/map/MapPicker.ts index 7cafbc56c..e2001306d 100644 --- a/src/client/components/map/MapPicker.ts +++ b/src/client/components/map/MapPicker.ts @@ -1,10 +1,12 @@ -import { LitElement, html } from "lit"; +import { html, LitElement } from "lit"; import { customElement, property, state } from "lit/decorators.js"; +import { repeat } from "lit/directives/repeat.js"; import { assetUrl } from "../../../core/AssetUrls"; import { Difficulty, GameMapType, mapCategories, + mapTranslationKeys, } from "../../../core/game/Game"; import { translateText } from "../../Utils"; import "./MapDisplay"; @@ -13,16 +15,6 @@ const randomMap = assetUrl("images/RandomMap.webp"); type MapTab = "featured" | "all" | "favorites"; -const featuredMaps: GameMapType[] = [ - GameMapType.World, - GameMapType.Europe, - GameMapType.NorthAmerica, - GameMapType.SouthAmerica, - GameMapType.Asia, - GameMapType.Africa, - GameMapType.Japan, -]; - @customElement("map-picker") export class MapPicker extends LitElement { @property({ type: String }) selectedMap: GameMapType = GameMapType.World; @@ -34,6 +26,7 @@ export class MapPicker extends LitElement { @property({ attribute: false }) onSelectMap?: (map: GameMapType) => void; @property({ attribute: false }) onSelectRandom?: () => void; @state() private activeTab: MapTab = "featured"; + @state() private expandedCategories: Set = new Set(); @state() private favorites: GameMapType[] = getFavoriteMaps(); createRenderRoot() { @@ -52,6 +45,16 @@ export class MapPicker extends LitElement { this.onSelectRandom?.(); }; + private toggleCategory(categoryKey: string) { + const expanded = new Set(this.expandedCategories); + if (expanded.has(categoryKey)) { + expanded.delete(categoryKey); + } else { + expanded.add(categoryKey); + } + this.expandedCategories = expanded; + } + private preventImageDrag(event: DragEvent) { event.preventDefault(); } @@ -76,50 +79,92 @@ export class MapPicker extends LitElement { .wins=${this.getWins(mapValue)} .favorite=${this.favorites.includes(mapValue)} .onToggleFavorite=${() => this.handleToggleFavorite(mapValue)} - .translation=${translateText(`map.${mapKey?.toLowerCase()}`)} + .translation=${translateText(mapTranslationKeys[mapValue])} > `; } - private renderAllMaps() { - const mapCategoryEntries = Object.entries(mapCategories); - return html`
- ${mapCategoryEntries.map( - ([categoryKey, maps]) => html` -
-

- ${translateText(`map_categories.${categoryKey}`)} -

-
- ${maps.map((mapValue) => this.renderMapCard(mapValue))} -
-
- `, + private renderMapGrid(maps: GameMapType[]) { + // Keyed by map so cards keep their identity when the list shifts + // (e.g. the selected map gets prepended to the featured grid) — + // positional reuse would leave stale thumbnails behind. + return html`
+ ${repeat( + maps, + (mapValue) => mapValue, + (mapValue) => this.renderMapCard(mapValue), )}
`; } - private renderFeaturedMaps() { - let featuredMapList = featuredMaps; - if (!this.useRandomMap && !featuredMapList.includes(this.selectedMap)) { - featuredMapList = [this.selectedMap, ...featuredMaps]; - } + private renderSectionHeading(label: string) { + return html`

+ ${label} +

`; + } + + private renderCategoryBar(categoryKey: string, maps: GameMapType[]) { + const expanded = this.expandedCategories.has(categoryKey); return html`
-

this.toggleCategory(categoryKey)} + class="w-full flex items-center justify-between gap-3 px-4 py-3 rounded-xl border transition-all duration-200 active:scale-[0.99] ${expanded + ? "bg-malibu-blue/20 border-malibu-blue/50" + : "bg-white/5 border-white/10 hover:bg-white/10 hover:border-white/20"}" > - ${translateText("map_categories.featured")} -

-
- ${featuredMapList.map((mapValue) => this.renderMapCard(mapValue))} -
+ + + ${translateText(`map_categories.${categoryKey}`)} + + ${maps.length} + + ${expanded + ? html`
${this.renderMapGrid(maps)}
` + : null}
`; } - private renderFavoriteMaps() { + private renderFeaturedTab() { + const featured = mapCategories.featured ?? []; + let featuredMapList = featured; + if (!this.useRandomMap && !featured.includes(this.selectedMap)) { + featuredMapList = [this.selectedMap, ...featured]; + } + return html`
+ ${this.renderSectionHeading(translateText("map_categories.featured"))} + ${this.renderMapGrid(featuredMapList)} +
`; + } + + private renderAllTab() { + return html`
+ ${Object.entries(mapCategories) + .filter(([categoryKey]) => categoryKey !== "featured") + .map(([categoryKey, maps]) => + this.renderCategoryBar(categoryKey, maps), + )} +
`; + } + + private renderFavoritesTab() { if (this.favorites.length === 0) { return html`
`; } return html`
-

- ${translateText("map_categories.favorites")} -

-
- ${this.favorites.map((mapValue) => this.renderMapCard(mapValue))} -
+ ${this.renderSectionHeading(translateText("map_categories.favorites"))} + ${this.renderMapGrid(this.favorites)}
`; } private renderActiveTab() { switch (this.activeTab) { case "all": - return this.renderAllMaps(); + return this.renderAllTab(); case "favorites": - return this.renderFavoriteMaps(); + return this.renderFavoritesTab(); default: - return this.renderFeaturedMaps(); + return this.renderFeaturedTab(); } } @@ -188,11 +227,7 @@ export class MapPicker extends LitElement { ? "pt-4 border-t border-white/5" : ""}" > -

- ${translateText("map_categories.special")} -

+ ${this.renderSectionHeading(translateText("map_categories.special"))}