Files
admin c61d286005 feat: wood inventory, carrying, and woodpile storage
Wood now follows the same gather-carry-deposit pattern as food. NPCs put harvested wood into inventory, walk to the VillageWoodpile StorageNode, and deposit it. Village wood syncs from storage. Player harvesting also routes wood to the woodpile. ActiveWorldAdapter exposes woodpile routing for DEPOSIT_WOOD action targeting. WorldViewManager recognizes wood inventory changes. Tests verify woodpile node existence, storage ID, navigation reachability, and adapter routing.
2026-07-08 18:55:51 +02:00

143 lines
6.6 KiB
Plaintext

[gd_scene format=3 uid="uid://rs3hv73svbpa"]
[ext_resource type="Script" uid="uid://4mg67crlim53" path="res://player/player.gd" id="1_h2yge"]
[ext_resource type="Script" uid="uid://ii8ai801jur2" path="res://player/camera_rig.gd" id="2_1bvp3"]
[ext_resource type="Script" uid="uid://dbb25ttlyogqr" path="res://simulation/SimulationManager.gd" id="3_lquwl"]
[ext_resource type="Script" uid="uid://c1f3b26n4yntf" path="res://world/world_view_manager.gd" id="4_1bvp3"]
[ext_resource type="PackedScene" uid="uid://dhxxyprqflotq" path="res://player/npc/NpcVisual.tscn" id="5_lquwl"]
[ext_resource type="Script" uid="uid://cjvbgqx8rao0t" path="res://world/ui/ui.gd" id="6_7mycd"]
[ext_resource type="Script" uid="uid://bbwol3mrjgn2x" path="res://world/active_world_adapter.gd" id="9_adapter"]
[ext_resource type="Script" uid="uid://cwvdljsh148wh" path="res://simulation/persistence/SaveSlotController.gd" id="10_save"]
[ext_resource type="PackedScene" path="res://world/jajce/JajceWorld.tscn" id="11_jajce"]
[ext_resource type="Script" uid="uid://cascjhf8lsvay" path="res://world/ui/time_dial.gd" id="12_timedial"]
[ext_resource type="Script" uid="uid://bivrsk5ukgnoo" path="res://world/demo/DemoController.gd" id="13_demo"]
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_o5qli"]
radius = 0.4
height = 1.7
[sub_resource type="CapsuleMesh" id="CapsuleMesh_sgp6g"]
[sub_resource type="BoxMesh" id="BoxMesh_0wfyh"]
[node name="Main" type="Node3D" unique_id=1850341560]
[node name="JajceWorld" parent="." unique_id=1023795383 instance=ExtResource("11_jajce")]
[node name="Player" type="CharacterBody3D" parent="." unique_id=2022843760 node_paths=PackedStringArray("camera_rig", "simulation_manager", "pantry_storage", "guard_site", "study_site")]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.05, 0)
script = ExtResource("1_h2yge")
camera_rig = NodePath("../CameraRig")
simulation_manager = NodePath("../SimulationManager")
pantry_storage = NodePath("../JajceWorld/WorldObjects/StorageSites/VillagePantry")
guard_site = NodePath("../JajceWorld/WorldObjects/ActivitySites/GuardPost")
study_site = NodePath("../JajceWorld/WorldObjects/ActivitySites/StudyDesk")
stomach_capacity_for_food = 10
[node name="CollisionShape3D" type="CollisionShape3D" parent="Player" unique_id=1249497228]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.85, 0)
shape = SubResource("CapsuleShape3D_o5qli")
[node name="MeshInstance3D" type="MeshInstance3D" parent="Player" unique_id=935946019]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.85, 0)
mesh = SubResource("CapsuleMesh_sgp6g")
[node name="FaceMarker" type="MeshInstance3D" parent="Player" unique_id=1558899356]
transform = Transform3D(0.15, 0, 0, 0, 0.15, 0, 0, 0, 0.4, 0, 1.2, 0.6266626)
mesh = SubResource("BoxMesh_0wfyh")
[node name="CameraRig" type="Node3D" parent="." unique_id=81378719 node_paths=PackedStringArray("target")]
transform = Transform3D(1, 0, 0, 0, 0.57357645, 0.81915206, 0, -0.81915206, 0.57357645, 0, 10, 8)
script = ExtResource("2_1bvp3")
target = NodePath("../Player")
follow_speed = 8.0
deadzone_right = 2.0
deadzone_forward = 2.0
max_zoom_offset = Vector3(0, 20, 15)
[node name="Camera3D" type="Camera3D" parent="CameraRig" unique_id=1992528776]
current = true
fov = 65.0
[node name="ActiveWorldAdapter" type="Node" parent="." unique_id=1773902505 node_paths=PackedStringArray("pantry_storage", "woodpile_storage")]
script = ExtResource("9_adapter")
pantry_storage = NodePath("../JajceWorld/WorldObjects/StorageSites/VillagePantry")
woodpile_storage = NodePath("../JajceWorld/WorldObjects/StorageSites/VillageWoodpile")
[node name="SimulationManager" type="Node" parent="." unique_id=1099676814 node_paths=PackedStringArray("active_world_adapter")]
script = ExtResource("3_lquwl")
active_world_adapter = NodePath("../ActiveWorldAdapter")
home_positions = Array[Vector3]([Vector3(-15, 2, 8.5), Vector3(-13.5, 2, 6.5), Vector3(-8.5, 2, 3), Vector3(-6.5, 2, 1.5), Vector3(-15, 2, -2.5), Vector3(-13.5, 2, -5)])
[node name="SaveSlotController" type="Node" parent="." unique_id=1281154019 node_paths=PackedStringArray("simulation_manager")]
script = ExtResource("10_save")
simulation_manager = NodePath("../SimulationManager")
[node name="WorldViewManager" type="Node" parent="." unique_id=763982891 node_paths=PackedStringArray("simulation_manager", "active_npcs_parent")]
script = ExtResource("4_1bvp3")
npc_visual_scene = ExtResource("5_lquwl")
simulation_manager = NodePath("../SimulationManager")
active_npcs_parent = NodePath("../ActiveNPCs")
[node name="EventBus" type="Node" parent="." unique_id=1149294963]
[node name="ActiveNPCs" type="Node3D" parent="." unique_id=88374680]
[node name="UI" type="CanvasLayer" parent="." unique_id=875790201 node_paths=PackedStringArray("simulation_manager")]
script = ExtResource("6_7mycd")
simulation_manager = NodePath("../SimulationManager")
[node name="VillagePanel" type="PanelContainer" parent="UI" unique_id=482126250]
offset_left = 20.0
offset_top = 20.0
offset_right = 280.0
offset_bottom = 140.0
[node name="MarginContainer" type="MarginContainer" parent="UI/VillagePanel" unique_id=60382506]
layout_mode = 2
theme_override_constants/margin_left = 12
theme_override_constants/margin_top = 4
theme_override_constants/margin_right = 12
theme_override_constants/margin_bottom = 4
[node name="VillageStatsLabel" type="Label" parent="UI/VillagePanel/MarginContainer" unique_id=1554319259]
layout_mode = 2
theme_override_font_sizes/font_size = 10
[node name="NpcInspectorPanel" type="PanelContainer" parent="UI" unique_id=1165556983]
anchors_preset = 1
anchor_left = 1.0
anchor_right = 1.0
offset_left = -370.0
offset_top = 20.0
offset_right = -20.0
offset_bottom = 330.0
grow_horizontal = 0
[node name="MarginContainer" type="MarginContainer" parent="UI/NpcInspectorPanel" unique_id=1227722850]
layout_mode = 2
theme_override_constants/margin_left = 16
theme_override_constants/margin_top = 12
theme_override_constants/margin_right = 16
theme_override_constants/margin_bottom = 12
[node name="NpcInspectorLabel" type="Label" parent="UI/NpcInspectorPanel/MarginContainer" unique_id=1036784952]
layout_mode = 2
theme_override_colors/font_color = Color(0.96, 0.91, 0.78, 1)
theme_override_font_sizes/font_size = 15
text = "Villager inspector"
[node name="TimeDial" type="Control" parent="UI" unique_id=191345668]
layout_mode = 3
anchors_preset = 0
offset_left = 880.0
offset_top = 6.0
offset_right = 940.0
offset_bottom = 66.0
script = ExtResource("12_timedial")
[node name="DemoController" type="Node" parent="." unique_id=644713371 node_paths=PackedStringArray("ui", "active_npcs_parent")]
script = ExtResource("13_demo")
ui = NodePath("../UI")
active_npcs_parent = NodePath("../ActiveNPCs")