Modern UI contract: nations, crests, photos, employments, allowed commands

TeamRef carries the world's nation and crest asset key, squad rows the
player's photo key. The manager's employments come from the almanac
(clubs and national team side by side), the desk's allowed commands
follow the desk kind. modern_world_info reports the asset coverage.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
ClaudeandClaude Opus 5.5 committed 2026-10-27 18:32:43 +01:00
1 parent 055b48697e
commit 6570384642
8 files changed
+102 -5

No files matched your search

+8
View File
@@ -45,6 +45,14 @@ int main(int argc, char** argv) {
std::printf("%d league clubs, %zu clubs in all; %zu players (%d original, %d without club, "
"%d with a Classic nationality code); league squads %d-%d\n",
league_clubs, w.clubs.size(), w.players.size(), legacy, without_team, coded, smallest, largest);
// asset keys and nations as the interface passes them on (TeamRef, squad rows)
int crests = 0, nations = 0, photos = 0;
for (const auto& c : w.clubs) crests += !c.crest.empty(), nations += !c.nation.empty();
for (const auto& p : w.players) photos += !p.photo.empty();
std::printf("clubs with crest %d, with nation %d; players with photo %d\n", crests, nations, photos);
if (!w.clubs.empty()) std::printf("e.g. club %s: nation %s, crest %s\n", w.clubs[0].id.c_str(), w.clubs[0].nation.c_str(), w.clubs[0].crest.c_str());
for (const auto& p : w.players)
if (!p.photo.empty()) { std::printf("e.g. player %s: photo %s\n", p.id.c_str(), p.photo.c_str()); break; }
return 0;
} catch (const std::exception& e) {
std::fprintf(stderr, "cannot open world: %s\n", e.what());