refactor: separate content from presentation assets

This commit is contained in:
Rijad Zuzo
2026-08-12 21:41:33 +02:00
parent 5a70aaaded
commit bf4bf73675
22 changed files with 480 additions and 70 deletions
+11 -2
View File
@@ -148,7 +148,7 @@ func rebuild(
storages, items_by_id, actions_by_id, capability_tags_by_id, supported_cues, errors
)
_validate_enemy_references(enemies, items_by_id, errors)
_validate_animal_references(animals, actions_by_id, errors)
_validate_animal_references(animals, actions_by_id, supported_cues, errors)
errors.sort()
_errors = errors
if not errors.is_empty():
@@ -708,9 +708,18 @@ static func _validate_enemy_references(
static func _validate_animal_references(
animals: Array[AnimalDefinition], actions_by_id: Dictionary, errors: Array[String]
animals: Array[AnimalDefinition],
actions_by_id: Dictionary,
supported_cues: Dictionary,
errors: Array[String]
) -> void:
for definition in animals:
_validate_presentation_cue(
"Animal '%s'" % definition.animal_definition_id,
definition.presentation_cue_id,
supported_cues,
errors
)
for action_id in definition.supported_action_ids:
if not actions_by_id.has(action_id):
errors.append(