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.
This commit is contained in:
@@ -2,6 +2,7 @@ class_name ActiveWorldAdapter
|
||||
extends Node
|
||||
|
||||
@export var pantry_storage: StorageNode
|
||||
@export var woodpile_storage: StorageNode
|
||||
|
||||
|
||||
func get_resource_candidates(action_id: StringName) -> Array[Dictionary]:
|
||||
@@ -38,6 +39,8 @@ func get_activity_target(action_id: StringName, origin: Vector3 = Vector3.ZERO)
|
||||
return _get_storage_target(pantry_storage)
|
||||
SimulationIds.ACTION_DEPOSIT_FOOD, SimulationIds.ACTION_WITHDRAW_FOOD:
|
||||
return _get_storage_target(pantry_storage)
|
||||
SimulationIds.ACTION_DEPOSIT_WOOD:
|
||||
return _get_storage_target(woodpile_storage)
|
||||
return {}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user