Save The Tree implementation and acceptance work in progress

Preserve production code, regression fixtures, audio assets and provenance, test infrastructure, and the original-completion plan and progress ledger. Final game and Windows acceptance remain pending; excluded local artifacts and native experiments are not part of this snapshot.
This commit is contained in:
Takeshi
2026-10-11 15:58:00 +09:00
parent 39f6068461
commit b84bade045
235 changed files with 495831 additions and 312 deletions
+19 -1
View File
@@ -35,7 +35,25 @@ func expect(ok: bool, message: String) -> void:
func run() -> void:
root.get_node("GameClock").set_paused(true)
var room := FacilityInstance.new().configure(&"room", &"cafeteria", {&"capacity": 99, &"customer_capacity": 6})
var dining_cells: Array[Vector3i] = [Vector3i(0, 0, 0), Vector3i(1, 0, 0), Vector3i(2, 0, 0), Vector3i(3, 0, 0), Vector3i(0, 1, 0), Vector3i(1, 1, 0), Vector3i(2, 1, 0), Vector3i(3, 1, 0)]
var kitchen_cells: Array[Vector3i] = [Vector3i(0, 0, 1), Vector3i(1, 0, 1), Vector3i(2, 0, 1), Vector3i(3, 0, 1), Vector3i(0, 1, 1), Vector3i(1, 1, 1), Vector3i(2, 1, 1), Vector3i(3, 1, 1)]
var room := FacilityInstance.new().configure(&"room", &"cafeteria", {&"occupied_cells": dining_cells, &"capacity": 99, &"customer_capacity": 6})
# Isolated presentation component fixture. No Runtime hire/attendance,
# physical route, normal business, or production kitchen acceptance is claimed.
expect(room.operation_state == FacilityInstance.OperationState.INACTIVE and Presentation.label(Presentation.describe(room), 3) == "未稼働", "unlinked component cafeteria is honestly inactive")
var dependencies := FacilityService.new()
var kitchen_definition: FacilityDefinition = load("res://data/facilities/kitchen.tres")
var kitchen := FacilityInstance.new().configure(&"presentation_kitchen", &"kitchen", {
&"origin": Vector3i(0, 0, WorldService.LAYER_BACK),
&"occupied_cells": kitchen_cells,
&"staff_min": kitchen_definition.staff_min, &"staff_max": kitchen_definition.staff_max,
&"active_staff_ids": [&"component_cook"],
&"access_available": true, &"power_available": true, &"operator_open": true,
})
expect(dependencies.register_instance(room).is_success(), "register same cafeteria before owned service fixture")
expect(dependencies.register_instance(kitchen).is_success(), "register controlled staffed BACK kitchen component")
expect(dependencies.set_operational_status(room.instance_id, {&"related_facility_id": kitchen.instance_id}, 0).is_success(), "component uses public single kitchen link")
expect(room.operation_state == FacilityInstance.OperationState.OPERATING and room.related_facility_id == kitchen.instance_id and kitchen.definition_id == &"kitchen" and kitchen.origin.z == WorldService.LAYER_BACK, "valid single BACK kitchen enables the original presentation fixture")
var service := ServiceInstance.new()
service.guest_ids.assign([&"f", &"a", &"c", &"e", &"b", &"d"])
room.active_services[&"service"] = service