The lounge and four buildings of the periphery can be extended in stages
Once it stands, the V.I.P. lounge goes up to four stages, the shopping centre and the clubhouse to three, the car park to four, the restaurant to two. A stage costs money and months of building and then brings a monthly income by league. The stadium page lists them under "Ausbaustufen". Engine: expansions.hpp, stadium read expansions, command stadium.expand; saved in state/modern.json. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This commit is contained in:
1 parent
57b8b0f371
commit
8be27f8e57
19 files changed
+391
-3
No files matched your search
@@ -194,6 +194,15 @@ void save_world_career(const std::filesystem::path& path, const World& world, co
|
||||
return J(std::move(rows));
|
||||
}()},
|
||||
{"dismissals", state.dismissals},
|
||||
{"expansions", [&] {
|
||||
A rows;
|
||||
for (const auto& e : state.expansions) {
|
||||
A stage, months;
|
||||
for (size_t k = 0; k < 5; ++k) stage.push_back(int64_t(e.stage[k])), months.push_back(int64_t(e.months[k]));
|
||||
rows.push_back(O{{"stage", std::move(stage)}, {"months", std::move(months)}});
|
||||
}
|
||||
return J(std::move(rows));
|
||||
}()},
|
||||
{"estates", [&] {
|
||||
A rows;
|
||||
for (const auto& held : state.estates) rows.push_back(A{J(int64_t(held[0])), J(int64_t(held[1])), J(int64_t(held[2])), J(int64_t(held[3]))});
|
||||
@@ -294,6 +303,19 @@ SavedWorldCareer load_world_career(const std::filesystem::path& path, const Worl
|
||||
if (const auto it = o->find("dismissals"); it != o->end() && std::holds_alternative<bool>(it->second.value))
|
||||
out.state.dismissals = std::get<bool>(it->second.value);
|
||||
}
|
||||
// further stages of lounge and periphery (since 17 November 2026)
|
||||
if (o->count("expansions"))
|
||||
for (const J& row : arr(get(modern, "expansions"))) {
|
||||
const A& stage = arr(get(row, "stage"));
|
||||
const A& months = arr(get(row, "months"));
|
||||
if (stage.size() != 5 || months.size() != 5) fail("invalid expansions");
|
||||
ModernState::Expansions e;
|
||||
for (size_t k = 0; k < 5; ++k) {
|
||||
if (num(stage[k]) < 0 || num(stage[k]) > 3 || num(months[k]) < 0 || num(months[k]) > 12) fail("invalid expansions");
|
||||
e.stage[k] = uint8_t(num(stage[k])), e.months[k] = uint8_t(num(months[k]));
|
||||
}
|
||||
out.state.expansions.push_back(e);
|
||||
}
|
||||
// the four further properties (since 17 November 2026)
|
||||
if (o->count("estates") && o->count("estate_prices")) {
|
||||
for (const J& row : arr(get(modern, "estates"))) {
|
||||
|
||||
Reference in new issue
Block a user