feat: define action completion costs
This commit is contained in:
@@ -204,6 +204,16 @@ func _test_wood_work_requires_material() -> void:
|
||||
),
|
||||
"Patrol should not consume partial wood or create safety when its full cost cannot be paid"
|
||||
)
|
||||
var blocked_events: Array[EconomicEventRecord] = manager.get_npc_events(npc.id, 2)
|
||||
_check(
|
||||
(
|
||||
not blocked_events.is_empty()
|
||||
and StringName(blocked_events[0].data["event_type"])
|
||||
== SimulationIds.EVENT_TASK_BLOCKED
|
||||
and "needs 1 Wood" in String(blocked_events[0].data.get("action_name", ""))
|
||||
),
|
||||
"An unpaid completion cost should create a readable blocked-task fact"
|
||||
)
|
||||
|
||||
manager.add_wood(1.5)
|
||||
_check(
|
||||
|
||||
Reference in New Issue
Block a user