fix(hero): export smoothing groups; give the facade real collision
UE export hygiene (unreal-export skill checklist) plus a gameplay defect the new probe caught: - FBX export now uses mesh_smooth_type="FACE" (was OFF, which is why every import logged "No smoothing group information was found"), and the round parts are shaded with shade_smooth_by_angle(35 deg) before export, so columns and medallions read round instead of faceted. - SM_HeroFacade had complex-only collision, so capsule sweeps and line traces passed through the wall: the player could walk through the hero facade. auto_generate_collision was tried and rejected (coarse hulls bulged into the street; the QA wall probe went 0/35 -> 2/35). It now uses UseComplexAsSimple, saved on the asset, like the terrain. - New -qaselftest facade occlusion probe: 40 m traces sideways from the road centre at walking height, required only where a building is staged (explicit X spans mirroring ue_build_demo_map). Result 0/9 -> PASS, alongside transect 0 holes and wall probe 0/35. Docs: release-checks records the probe and both collision attempts; Tools/README lists the new phase; MEMORY records the smoothing/collision lessons.
This commit is contained in:
1 parent
70c6e322e2
commit
160e9144f9
32 files changed
+166
-45
No files matched your search
+1
-1
@@ -57,7 +57,7 @@ Geographic tools live in [`Geo/tools/`](../Geo/README.md) and the Blender-side b
|
||||
| Command | Purpose |
|
||||
| --- | --- |
|
||||
| `UnrealEditor <uproject> /Game/Hollywood/DemoMap -game -qaselftest` | Headless behaviour check: drives forward input for 2 s, then resets and pauses. Logs `GigLine QA: ... PASS/FAIL` lines and a final `RESULT`. Runs only with `-qaselftest`, so normal play is unaffected. |
|
||||
| `-qaselftest` phases | Walk, reset, pause/unpause, a 16-row seam transect (0 holes) and a ground-referenced wall probe (0/35), plus a frame-time capture writing `Saved/Profiling/perf-walk-frametimes.csv` and logging `GigLine PERF:`. |
|
||||
| `-qaselftest` phases | Walk, reset, pause/unpause, a 16-row seam transect (0 holes), a ground-referenced wall probe (0/35) and a **facade occlusion probe** that fires sideways from the road centre and requires a blocking wall wherever a building is staged (0/9), plus a frame-time capture writing `Saved/Profiling/perf-walk-frametimes.csv` and logging `GigLine PERF:`. |
|
||||
| `gigline.SetupLogs` cvar | Spawn/input setup logging, **off by default** (`DefaultEngine.ini [ConsoleVariables]`); enable at runtime with `gigline.SetupLogs 1`. |
|
||||
|
||||
## Reference and concept generation
|
||||
|
||||
@@ -74,7 +74,7 @@ def cube(name, x, y, z, dx, dy, dz, material=None):
|
||||
return obj
|
||||
|
||||
|
||||
def cylinder(name, x, y, z0, z1, radius, material, vertices=24):
|
||||
def cylinder(name, x, y, z0, z1, radius, material, vertices=24, smooth=True):
|
||||
bpy.ops.mesh.primitive_cylinder_add(
|
||||
vertices=vertices,
|
||||
radius=radius,
|
||||
@@ -85,6 +85,11 @@ def cylinder(name, x, y, z0, z1, radius, material, vertices=24):
|
||||
obj.name = name
|
||||
if material:
|
||||
obj.data.materials.append(material)
|
||||
if smooth:
|
||||
# Round parts must shade smoothly *around* the axis while keeping the
|
||||
# caps creased. Without this the columns read as faceted prisms, and the
|
||||
# FBX carries no smoothing groups at all (Unreal warns about it).
|
||||
bpy.ops.object.shade_smooth_by_angle(angle=math.radians(35.0))
|
||||
return obj
|
||||
|
||||
|
||||
@@ -313,7 +318,9 @@ def export_fbx(path):
|
||||
axis_up="Z",
|
||||
use_space_transform=True,
|
||||
use_mesh_modifiers=True,
|
||||
mesh_smooth_type="OFF",
|
||||
# "FACE" exports smoothing groups; without it every import logs
|
||||
# "No smoothing group information was found for this mesh".
|
||||
mesh_smooth_type="FACE",
|
||||
path_mode="AUTO",
|
||||
bake_space_transform=False,
|
||||
)
|
||||
|
||||
@@ -61,6 +61,16 @@ def measure_and_place():
|
||||
if asset is None:
|
||||
log(f"MISSING {DEST}/SM_HeroFacade")
|
||||
return
|
||||
# Collision: complex-as-simple, not auto-generated convex hulls.
|
||||
# The facade is 95 separate parts across 26 m; Unreal's auto hull generation
|
||||
# wraps them in a few coarse hulls that bulged into the street (the QA wall
|
||||
# probe went 0/35 -> 2/35 after trying it). Complex-as-simple makes the real
|
||||
# triangles the simple collision, so line traces and capsule sweeps block on
|
||||
# the actual wall — the same approach used for the terrain, for the same
|
||||
# reason. The flag lives on the asset, so save it explicitly.
|
||||
unreal.GigLineAssetTools.set_complex_collision_as_simple(asset, True)
|
||||
saved = unreal.EditorAssetLibrary.save_loaded_asset(asset)
|
||||
log(f"collision: {unreal.GigLineAssetTools.get_collision_complexity(asset)} (saved={saved})")
|
||||
box = asset.get_bounding_box()
|
||||
mn, mx = box.min, box.max
|
||||
log(f"SM_HeroFacade bounds cm: size=({mx.x - mn.x:.1f}, {mx.y - mn.y:.1f}, {mx.z - mn.z:.1f}) "
|
||||
|
||||
Reference in new issue
Block a user