Add comprehensive civilization evolution tests and enhance civilization state management
- Introduced a new test script for civilization evolution (`test_civilization_evolution.gd`) to validate the evolution mechanics, including population dynamics, ethical transitions, and war impacts. - Updated `README.md` to include instructions for running the new civilization evolution tests. - Modified `test_civilization_state.gd` to accommodate changes in civilization rules and ensure proper validation of ethical stages. - Enhanced `test_descriptions.gd` to check for accurate population counters and state validation. - Adjusted `test_life.gd` to reflect updates in life version management. - Improved `civilization_state.gd` to include habitat budget calculations and transition management. - Added `civilization_evolution.gd` to handle the logic for civilization evolution, including population drift, warfare, and colonization mechanics. - Updated `owniverse.gd` and `owniverse_entity.gd` to integrate new evolution logic and ensure proper initialization of entities.
This commit is contained in:
+1
-1
@@ -103,7 +103,7 @@ func run() -> void:
|
||||
world.state.life_version = 1
|
||||
world.state.amount["C0.0"] = 40000.0
|
||||
world.initialize_life_batches()
|
||||
check(world.state.life_version == 2 and world.state.batches["C0.0"][0].created_from == 123.4, "Previous life saves receive missing civilization cohorts")
|
||||
check(world.state.life_version == 3 and world.state.batches["C0.0"][0].created_from == 123.4, "Previous life saves receive missing civilization cohorts")
|
||||
before = world.state.duplicate(true)
|
||||
world.initialize_life_batches()
|
||||
check(world.state == before, "Second life migration is idempotent")
|
||||
|
||||
Reference in New Issue
Block a user