NEO-74: Repopulate recipe panel when item defs load.

Run craft panel refresh before inventory-error guard in
_on_item_definitions_ready so display names resolve even when
inventory GET failed first.
pull/108/head
VinPropane 2026-05-24 20:21:37 -04:00
parent d6d95ec438
commit a8cedcbd64
2 changed files with 2 additions and 1 deletions

View File

@ -366,11 +366,11 @@ func _apply_authority_http_config_to_client(client: Node) -> void:
func _on_item_definitions_ready(_definitions_by_id: Dictionary) -> void: func _on_item_definitions_ready(_definitions_by_id: Dictionary) -> void:
_populate_craft_recipe_panel_if_ready()
if not _inventory_error.is_empty(): if not _inventory_error.is_empty():
return return
if not _last_inventory_snapshot.is_empty(): if not _last_inventory_snapshot.is_empty():
_render_inventory_label() _render_inventory_label()
_populate_craft_recipe_panel_if_ready()
func _on_inventory_received(snapshot: Dictionary) -> void: func _on_inventory_received(snapshot: Dictionary) -> void:

View File

@ -1,6 +1,7 @@
extends GdUnitTestSuite extends GdUnitTestSuite
## NEO-74: `RecipeDefinitionsClient` GET parse + `recipes_ready` signal. ## NEO-74: `RecipeDefinitionsClient` GET parse + `recipes_ready` signal.
## `main.gd` repopulates craft panel on item `definitions_ready` even when inventory GET failed.
const RecipeDefinitionsClient := preload("res://scripts/recipe_definitions_client.gd") const RecipeDefinitionsClient := preload("res://scripts/recipe_definitions_client.gd")