feat(cellular): seed dev wildlife and tune budding playtests
Foundation / checks (client) (push) Successful in 5s
Foundation / checks (checks) (push) Successful in 5s
Foundation / checks (ecs) (push) Successful in 4s
Foundation / checks (postgres) (push) Successful in 4s
Foundation / checks (network) (push) Successful in 5s
Foundation / checks (tsan) (push) Successful in 4s
Foundation / checks (deploy) (push) Successful in 4m27s
Foundation / postgres-tools (push) Successful in 30s
Foundation / server-image (push) Successful in 4m16s
Foundation / image (push) Successful in 4m54s

This commit is contained in:
dingo
2026-10-26 12:01:57 -04:00
parent 18a64a29cd
commit ff121c3ed1
32 changed files with 738 additions and 78 deletions
+16 -7
View File
@@ -19,9 +19,10 @@ void check(bool condition, std::source_location at = std::source_location::curre
CellularRevampTuning trial() {
CellularRevampTuning t{.version = 1,
.playtest_starting_wildlife_cells = 32,
.body_essential_upkeep_per_mille = 250,
.body_reserve_load_per_mille = 1'000,
.body_growth_per_tick_centi_mille = 500,
.body_growth_per_tick_centi_mille = 625,
.energy_burn_carbon_pj_per_kfg = 2'000,
.energy_burn_nitrogen_pj_per_kfg = 2'000,
.energy_burn_phosphorus_pj_per_kfg = 2'000,
@@ -49,12 +50,12 @@ CellularRevampTuning trial() {
.mutation_buds_for_adhesion = 5,
.reproduction_split_share_per_mille = 500,
.reproduction_split_min_growth_per_mille = 500,
.reproduction_bud_fee_e_pj = 0,
.reproduction_bud_fee_c_fg = 0,
.reproduction_bud_fee_n_fg = 0,
.reproduction_bud_fee_p_fg = 0,
.reproduction_bud_fee_o_fg = 0,
.reproduction_bud_fee_scale_percent = 0,
.reproduction_bud_fee_e_pj = 250'000,
.reproduction_bud_fee_c_fg = 100'000,
.reproduction_bud_fee_n_fg = 30'000,
.reproduction_bud_fee_p_fg = 10'000,
.reproduction_bud_fee_o_fg = 60'000,
.reproduction_bud_fee_scale_percent = 100,
.reproduction_organism_cap = 256,
.organism_load_per_mille = 500,
.organism_emerge_members = 8,
@@ -130,6 +131,14 @@ void canonical_round_trip() {
void refusals() {
const auto base = encode_cellular_revamp_tuning(trial());
CHECK(error_of(with(base, "playtest.starting_wildlife_cells", "256")) ==
CellularTuningErrorKind::out_of_range);
CHECK(error_of(with(base, "playtest.starting_wildlife_cells", "-1")) ==
CellularTuningErrorKind::out_of_range);
auto legacy = base;
const auto start = legacy.find("playtest.starting_wildlife_cells");
legacy.erase(start, legacy.find('\n', start) - start + 1);
CHECK(parse_cellular_revamp_tuning(legacy)->playtest_starting_wildlife_cells == 0);
CHECK(error_of(base + "unknown.key = 1\n") == CellularTuningErrorKind::unknown_key);
CHECK(error_of(base + "tuning.version = 1\n") == CellularTuningErrorKind::duplicate_key);
CHECK(error_of(base + "no equals sign\n") == CellularTuningErrorKind::syntax);