A player's card with figures and skills; shirts in the club's colour; table zones; reduced motion

The card shows age, strength, condition, technique and form as numerals, the seven
skills as marks and contract and status as a list. The line-up pitch draws shirts in
the club's colour with a condition dot instead of the data set's figures. League
tables carry the prediction's European places and the promotion and relegation
places. A display setting turns transitions off. The desk hangs from the top edge of
a taller screen.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This commit is contained in:
MichaelandClaude Fable 5.2 committed 2026-11-14 18:43:40 +01:00
1 parent 9b33e1f8c1
commit eec7f40a52
16 files changed
+160 -26

No files matched your search

+10 -3
View File
@@ -26,7 +26,8 @@ Json default_ui_preferences() {
{{"mode", "window"},
{"resolution", "1920x1080"},
{"scale", "auto"},
{"language", "de"}}},
{"language", "de"},
{"motion", "full"}}},
{"sound", {{"volume", 80}, {"effects", true}, {"style", "classic"}}}};
}
bool valid_ui_preferences(const Json &v) {
@@ -35,7 +36,8 @@ bool valid_ui_preferences(const Json &v) {
!choice(v.at("theme"), {"midnight", "silver", "matchday"}))
return false;
const auto &d = v.at("display"), &s = v.at("sound");
return keys(d, {"mode", "resolution", "scale", "language"}) &&
return keys(d, {"mode", "resolution", "scale", "language", "motion"}) &&
choice(d.at("motion"), {"full", "reduced"}) &&
keys(s, {"volume", "effects", "style"}) &&
choice(d.at("mode"), {"window", "fullscreen"}) &&
choice(d.at("resolution"), {"1280x720", "1600x900", "1920x1080",
@@ -68,7 +70,12 @@ Json legacy_ui_preferences(const Json &legacy) {
Json load_ui_preferences(const fs::path &path) {
if (!fs::exists(path))
return default_ui_preferences();
const auto envelope = Json::parse(editor::read_file(path));
auto envelope = Json::parse(editor::read_file(path));
// a file written before the motion setting existed keeps full motion
if (envelope.is_object() && envelope.contains("preferences") && envelope["preferences"].is_object() &&
envelope["preferences"].contains("display") && envelope["preferences"]["display"].is_object() &&
!envelope["preferences"]["display"].contains("motion"))
envelope["preferences"]["display"]["motion"] = "full";
if (!keys(envelope, {"schema", "preferences"}) ||
envelope.at("schema") != "openbmh-ui-preferences@1" ||
!valid_ui_preferences(envelope.at("preferences")))