Files
OpenFrontIO/map-generator/assets/maps/mississippiriver/info.json
T
Evan 3de5fb4204 Move map metadata into info.json and generate map TypeScript from it (#4227)
**Add approved & assigned issue number here:**

N/A — maintainer refactor.

## Description:

Makes each map's `info.json` the single source of truth for map metadata
— adding a map is now a folder with `image.png` + `info.json`, a
`gen-maps` run, and an en.json display name.

**info.json / manifest.json carry full map metadata.** Every
`map-generator/assets/maps/<map>/info.json` declares `id` (the
`GameMapType` enum key), `name` (the enum value — wire format, unchanged
for all 94 maps), `translation_key`, `categories`, and
`multiplayer_frequency` (the public-playlist weight that used to be the
`FREQUENCY` record in MapPlaylist.ts). The generator validates
everything and mirrors it into `resources/maps/<map>/manifest.json`. 23
stale info.json `name` values were normalized to the canonical enum
value; enum values are byte-identical, so replays and stored game
configs are unaffected.

**The generator emits the TypeScript and discovers maps itself.** New
`map-generator/codegen.go` generates `src/core/game/Maps.gen.ts`
(`GameMapType`, `GameMapName`, `mapCategories`, `mapTranslationKeys`,
`multiplayerFrequency` — now a full `Record<GameMapName, number>`,
killing the old `Partial`) on every run; `Game.ts` re-exports it. The
hardcoded map registry in `main.go` is gone — maps are auto-discovered
from the `assets/maps` / `assets/test_maps` directories. MapConsistency
tests fail with a "run `npm run gen-maps`" message if info.json,
manifest.json, and Maps.gen.ts drift. The tracked
`map-generator/map-generator` binary is rebuilt to match.

**New categories: continents + world/cosmic/tournament/other,
multi-category support.** `continental`/`regional`/`fantasy`/`arcade`
are replaced by `featured`, `world`, `europe`, `asia`, `north_america`,
`africa`, `south_america`, `oceania`, `antarctica`, `cosmic`,
`tournament`, and `other`. Maps can list multiple categories, so
straddlers (Black Sea, Bosphorus, Caucasus, Between Two Seas, Bering
Sea/Strait, Mena, Strait of Gibraltar, Hawaii, Arctic) appear under both
regions. Featured is itself a category (same 7 maps as before).
MapPlaylist keeps its arcade exclusion via an explicit set.

**Map picker UI.** Two tabs: **Featured** (default — featured maps plus
a Favorites section when maps are starred) and **All** (one prominent
collapsible bar per category with a map count, collapsed by default).
The selected map is prepended to the featured grid when it lives
elsewhere. `getMapName()` resolves through the generated
`mapTranslationKeys`, which also fixes tourney maps never resolving a
valid translation key.

## Please complete the following:

- [ ] I have added screenshots for all UI updates (maintainer change —
picker described above)
- [x] I process any text displayed to the user through translateText()
and I've added it to the en.json file
- [x] I have added relevant tests to the test directory

## Please put your Discord username so you can be contacted if a bug or
regression is found:

evanpelle

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-06-11 19:36:53 -07:00

322 lines
6.2 KiB
JSON

{
"id": "MississippiRiver",
"name": "Mississippi River",
"translation_key": "map.mississippiriver",
"categories": ["north_america"],
"multiplayer_frequency": 3,
"nations": [
{
"coordinates": [390, 269],
"name": "Memphis",
"flag": "Tennessee"
},
{
"coordinates": [89, 50],
"name": "Marion",
"flag": "Arkansas"
},
{
"coordinates": [174, 1804],
"name": "Helena-West Helena",
"flag": "Arkansas"
},
{
"coordinates": [329, 3385],
"name": "Rosedale",
"flag": "Mississippi"
},
{
"coordinates": [113, 4031],
"name": "Arkansas City",
"flag": "Arkansas"
},
{
"coordinates": [89, 2510],
"name": "Elaine",
"flag": "Arkansas"
},
{
"coordinates": [330, 2162],
"name": "Friars Point",
"flag": "Mississippi"
},
{
"coordinates": [365, 1251],
"name": "Tunica",
"flag": "Mississippi"
},
{
"coordinates": [182, 800],
"name": "Horseshoe Lake",
"flag": "Arkansas"
},
{
"coordinates": [378, 2490],
"name": "Clarksdale",
"flag": "Mississippi"
},
{
"coordinates": [185, 308],
"name": "West Memphis",
"flag": "Arkansas"
}
],
"additionalNations": [
{
"coordinates": [304, 87],
"name": "Harbor Town",
"flag": "Tennessee"
},
{
"coordinates": [395, 4],
"name": "Frayser",
"flag": "Tennessee"
},
{
"coordinates": [383, 510],
"name": "Westwood",
"flag": "Tennessee"
},
{
"coordinates": [90, 473],
"name": "Edmondson",
"flag": "Arkansas"
},
{
"coordinates": [20, 690],
"name": "Anthonyville",
"flag": "Arkansas"
},
{
"coordinates": [395, 3552],
"name": "Beulah",
"flag": "Mississippi"
},
{
"coordinates": [220, 3872],
"name": "Eutaw",
"flag": "Mississippi"
},
{
"coordinates": [394, 3866],
"name": "Bolivar",
"flag": "Mississippi"
},
{
"coordinates": [11, 3227],
"name": "Benzal",
"flag": "Arkansas"
},
{
"coordinates": [23, 3865],
"name": "Rohwer",
"flag": "Arkansas"
},
{
"coordinates": [17, 3752],
"name": "Duce",
"flag": "Arkansas"
},
{
"coordinates": [41, 3606],
"name": "Kelso",
"flag": "Arkansas"
},
{
"coordinates": [339, 3297],
"name": "Wright",
"flag": "Mississippi"
},
{
"coordinates": [339, 3159],
"name": "Waxhaw",
"flag": "Mississippi"
},
{
"coordinates": [336, 3098],
"name": "Gunnison",
"flag": "Mississippi"
},
{
"coordinates": [341, 2994],
"name": "Deeson",
"flag": "Mississippi"
},
{
"coordinates": [303, 2764],
"name": "Hillhouse",
"flag": "Mississippi"
},
{
"coordinates": [378, 2790],
"name": "Alligator",
"flag": "Mississippi"
},
{
"coordinates": [306, 2393],
"name": "Farell",
"flag": "Mississippi"
},
{
"coordinates": [14, 2738],
"name": "Mellwood",
"flag": "Arkansas"
},
{
"coordinates": [28, 2894],
"name": "Crumrod",
"flag": "Arkansas"
},
{
"coordinates": [350, 2679],
"name": "Rena Lara",
"flag": "Mississippi"
},
{
"coordinates": [247, 2599],
"name": "Sherards",
"flag": "Mississippi"
},
{
"coordinates": [61, 3050],
"name": "Snow Lake",
"flag": "Arkansas"
},
{
"coordinates": [252, 2121],
"name": "Westover",
"flag": "Arkansas"
},
{
"coordinates": [55, 2168],
"name": "Lake View",
"flag": "Arkansas"
},
{
"coordinates": [45, 2335],
"name": "Wabash",
"flag": "Arkansas"
},
{
"coordinates": [28, 1757],
"name": "West Helena",
"flag": "Arkansas"
},
{
"coordinates": [372, 1851],
"name": "Lula",
"flag": "Mississippi"
},
{
"coordinates": [47, 2008],
"name": "Oneida",
"flag": "Arkansas"
},
{
"coordinates": [358, 1699],
"name": "Dundee",
"flag": "Mississippi"
},
{
"coordinates": [355, 1567],
"name": "Maud",
"flag": "Mississippi"
},
{
"coordinates": [368, 1436],
"name": "Clayton",
"flag": "Mississippi"
},
{
"coordinates": [271, 1436],
"name": "Austin",
"flag": "Mississippi"
},
{
"coordinates": [92, 1291],
"name": "Whitehall",
"flag": "Arkansas"
},
{
"coordinates": [4, 1097],
"name": "Council",
"flag": "Arkansas"
},
{
"coordinates": [12, 840],
"name": "Hughes",
"flag": "Arkansas"
},
{
"coordinates": [374, 1094],
"name": "Hollywood",
"flag": "Mississippi"
},
{
"coordinates": [369, 1002],
"name": "Bowdre",
"flag": "Mississippi"
},
{
"coordinates": [369, 882],
"name": "Penton",
"flag": "Mississippi"
},
{
"coordinates": [238, 701],
"name": "Norfolk",
"flag": "Mississippi"
},
{
"coordinates": [389, 631],
"name": "Walls",
"flag": "Mississippi"
},
{
"coordinates": [378, 714],
"name": "Glover",
"flag": "Mississippi"
},
{
"coordinates": [188, 469],
"name": "Amanca",
"flag": "Arkansas"
},
{
"coordinates": [386, 381],
"name": "South Memphis",
"flag": "Tennessee"
},
{
"coordinates": [395, 191],
"name": "North Memphis",
"flag": "Tennessee"
},
{
"coordinates": [57, 565],
"name": "Midway Corner",
"flag": "Arkansas"
},
{
"coordinates": [7, 4190],
"name": "Halley",
"flag": "Arkansas"
},
{
"coordinates": [394, 4134],
"name": "Lamont",
"flag": "Mississippi"
},
{
"coordinates": [389, 3713],
"name": "Dahomy",
"flag": "Mississippi"
},
{
"coordinates": [296, 2896],
"name": "Round Lake",
"flag": "Mississippi"
}
]
}