diff --git a/src/game/engine/scenes/headless/claude_player_main.gd b/src/game/engine/scenes/headless/claude_player_main.gd index c013b34b..d7a9482c 100644 --- a/src/game/engine/scenes/headless/claude_player_main.gd +++ b/src/game/engine/scenes/headless/claude_player_main.gd @@ -192,7 +192,16 @@ func _apply_runtime_units_catalog(gs: RefCounted) -> void: dir.list_dir_begin() var fname: String = dir.get_next() while fname != "": - if not dir.current_is_dir() and fname.ends_with(".json"): + # Skip `*.schema.json` — those are JSON Schema descriptors that + # live alongside the unit data files but describe the shape, not + # instances of it. Including them would feed the deserializer + # `{"$schema": "...", "type": "object", "properties": {...}}` + # without an `id` field, which correctly rejects. + if ( + not dir.current_is_dir() + and fname.ends_with(".json") + and not fname.ends_with(".schema.json") + ): var path: String = UNITS_DIR + "/" + fname var f: FileAccess = FileAccess.open(path, FileAccess.READ) if f != null: