feat: derive capable opportunity helpers

This commit is contained in:
Rijad Zuzo
2026-07-16 10:41:05 +02:00
parent 79dd503343
commit eaa15c076c
17 changed files with 648 additions and 40 deletions
@@ -38,6 +38,15 @@ func get_relationship(observer_id: int, subject_id: int) -> RelationshipStateRec
return relationships.get(_key(observer_id, subject_id)) as RelationshipStateRecord
func is_trusted_for_help(observer_id: int, subject_id: int) -> bool:
var relationship := get_relationship(observer_id, subject_id)
return (
relationship != null
and relationship.get_familiarity() > 0.0
and relationship.get_trust() >= TRUSTED_HELP_THRESHOLD
)
func increase_shared_work_familiarity(first_id: int, second_id: int) -> void:
var first_to_second := _get_or_create(first_id, second_id)
var second_to_first := _get_or_create(second_id, first_id)