feat: unify authored activity commands

This commit is contained in:
Rijad Zuzo
2026-08-13 00:08:30 +02:00
parent e5aecee0de
commit b3b98c6456
36 changed files with 3013 additions and 96 deletions
+15
View File
@@ -114,6 +114,21 @@ func test_economy_moves_inventory_into_authoritative_storage() -> void:
assert_eq(village.food, 5.0)
func test_economy_routes_authored_items_without_resource_switches() -> void:
var village := SimVillage.new()
var economy := VillageEconomyScript.new()
economy.configure(village, false)
economy.initialize_storage()
var apothecary := economy.get_storage_for_resource(&"herb")
assert_not_null(apothecary)
assert_eq(apothecary.get_storage_id(), &"village_apothecary")
assert_same(economy.get_storage_for_resource(SimulationIds.RESOURCE_FOOD), economy.get_pantry())
assert_same(
economy.get_storage_for_resource(SimulationIds.RESOURCE_WOOD), economy.get_woodpile()
)
func test_failed_food_consumption_preserves_fractional_inventory() -> void:
var village := SimVillage.new()
var economy := VillageEconomyScript.new()