feat(hair): hair cards as their own skinned mesh, attached as a second component
Follows the character-artist skill on two points it is explicit about: hair for a game character is a card system, and swappable parts stay separate meshes. - Tools/character_hair_build.py builds SM_Char_Hair: a scalp cap plus 18 cards in three rings, quads only, every vertex weighted 1.0 to the head bone, UV-mapped for the strand sheet from Tools/generate_character_textures.py. 321 verts / 404 tris. - Tools/ue_character_hair_import.py imports it as its own skeletal mesh, which is the point: joined into the body, Unreal collapses the second material slot and the hair renders with the skin material. - The pawn carries it as a second USkeletalMeshComponent on SetLeaderPoseComponent, so it follows the head bone with no second rig and hides with the body in first person. Still wrong and recorded: the cards point outward, so the silhouette reads as a spiked crown rather than a short cut. The next pass orients them tangentially along the skull with a second overlapping row. Tools/ue_character_materials.py also segfaults in the headless commandlet when editing a material graph, so the generated textures are not wired yet and the hair keeps its Blender base colour.
This commit is contained in:
1 parent
72d00bdfbd
commit
39f07b0f5f
46 files changed
+519
-47
No files matched your search
@@ -155,6 +155,17 @@ protected:
|
||||
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Camera")
|
||||
float ThirdPersonBoomLength = 340.0f;
|
||||
|
||||
/**
|
||||
* Hair, as its own skeletal mesh following the body's pose.
|
||||
*
|
||||
* A second component rather than geometry joined into the body: Unreal collapses
|
||||
* the second material slot on a skeletal-mesh import, so joined hair rendered with
|
||||
* the skin material. The character-artist skill calls for hair cards to be their
|
||||
* own mesh for the same reason it calls for swappable parts to be separate.
|
||||
*/
|
||||
UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category = "Body")
|
||||
TObjectPtr<USkeletalMeshComponent> HairMesh;
|
||||
|
||||
UPROPERTY()
|
||||
TObjectPtr<UAnimSequence> IdleAnimation;
|
||||
|
||||
|
||||
Reference in new issue
Block a user