fix(input): restore working controls + add input harness + build fixes

Consolidated from the qa-input-collision-fix-0.1.0 work, applied onto main so
only the changes main genuinely lacks are carried (main already merged the
walkable-demo/collision work independently).

- fix(input): populate the UE 5.8 FInputMappingContextMappingData
  DefaultKeyMappings field in ue_create_input_assets.py (the runtime reads
  GetMappings()->DefaultKeyMappings.Mappings; the script previously wrote only
  the deprecated 'mappings' array, so the cooked game had 0 runtime mappings
  and every key silently did nothing — in packaged AND PIE). Regenerated
  IMC_Default.uasset. WASD/mouse/Space/R/Escape verified working.
- fix(build): drop editor-only APIs that break the game target build —
  UStaticMesh::PostEditChange() (GigLineAssetTools) and AActor::GetActorLabel()
  (character ground probe). GigLine and GigLineEditor now both compile clean.
- tools: OS-level uinput input harness (input_emulation.py + input_test.py) and
  run_pie.sh for PIE isolation; document the PIE-vs-packaged input test in
  Docs/build.md. Removed the temporary SIM/EI/screenshot diagnostics from the
  character.
This commit is contained in:
zwitschi committed 2026-11-08 13:43:33 +01:00
1 parent 6b4e1252c5
commit 4832e66c00
8 files changed
+639 -56

No files matched your search

+11 -1
View File
@@ -149,8 +149,18 @@ def build():
except Exception as exc: # noqa: BLE001
log(f"skip {action.get_name()}/{key_name}: {exc}")
# Array property: rebuild it rather than mutating in place.
# UE 5.8: the runtime reads DefaultKeyMappings.Mappings (FInputMappingContextMappingData),
# NOT the deprecated 'mappings' array on the context. The deprecated array is
# what editor UI shows and what the old script wrote, so the cooked game got 0
# runtime mappings (key->action lookup failed -> no input). Populate the new
# struct field that the runtime actually consumes.
default_mapping_data = imc.get_editor_property("default_key_mappings")
if default_mapping_data is None:
default_mapping_data = unreal.InputMappingContextMappingData()
default_mapping_data.set_editor_property("mappings", mappings)
# Mirror into the deprecated array so the editor UI and any legacy reader agree.
imc.set_editor_property("mappings", mappings)
imc.set_editor_property("default_key_mappings", default_mapping_data)
save(imc)
log(f"IA_Move={ia_move.get_path_name()} IA_Look={ia_look.get_path_name()} "