Hello and thank you for your attention. Sorry for the somewhat long post, but I want to provide all my fidings.
I have a modular character creator which generates characters by combining several different parts. I’m synchronizing animations with Copy Pose From Mesh, with one part serving as the master part. The whole reason I decided to go with Copy Pose From Mesh is that it allows skeletons to be extended, and theoretically works with the physics engine. Unfortunately, when I activate physics simulation on *all *the parts, the children lag behind the master by what I assume to be one frame. There seems to be no fixing it other than disabling physics simulation.
I tried moving all the slave parts to a tick group that runs after the physics engine using SetTickGroup() and it doesn’t work. I tried forcing all the slave parts to tick after the master part with AddTickPrerequisiteComponent() and it also doesn’t have any effect. What does work is disabling physics.
After re-reading the documentation, it seems Copy Pose From Mesh does not work properly when physics simulation is enabled:
This suggests I should be able to enable physics on the master part at least, as long as the child parts are not simulating. Sure enough, with only the master simulating, everything seems synchronized *provided *I move all the children to a tick group that runs after the physics calculations. I assume this is because enabling physics forces components to tick only in the ETickingGroup::TG_DuringPhysics step, so if I enable physics on everything, everything gets thrown there and the order of execution is unknown, with children that run before the master copying the last frame’s data.
In conclusion, am I correct to assume there is no way to enable physics on all the parts at once if one needs things to remain in sync? If so, what is the recommended approach to applying physics to the children? The Rigid Body node?
Hello!
I’m fighting with exactly the same problem.
As a workaround, what I could do is to make an AnimBP:
Input Pose -> Local To Component -> RigidBody -> ComponentToLocal->Output Pose
On the rigid body, I set the Simulation Space to World Space, and setup the overlap channel ( i have this on custom ). Then I set this animBP to my hair mesh as Post Process Anim Blueprint.
This way even if the main body is physics controlled, the hair physics works.
However, this “RigidBody” physics is really unrealiable. I have a lot of stretching, many joints ignored, etc. I dont like this method, but at least it works.
If you find out how to get the normal simulated physics working, let me know!
Master pose doesnt work if the slave does not have exactly the same bones as master.
And somehow my physics works now? Here is what I did, not sure if all of these are needed, but it’s working for now, so I don’t want to play with it anymore
And it… works? No more lagging behind. Probably the TickGroup and EndTickGroup settings fixed it. “ClothPhysics” is just a collision profile I made so it does not collide with the pawn’s capsule collider, and so on.
Hope this helps
if you have a character with different skeletal meshes, I found the only way to get the anims work in sync is to disable and re-enable them (in my case horse + rider + bow) by NoSkeletonUpdate (set to true, use a short e.g. 0.1s Delay, then set to false).
I don’t know when this started happening for us, but I believe it started in 5.3. It appears that copy pose gets a one frame lag whenever bEnableUpdateRateOptimizations is enabled on a child mesh. It works perfectly when leader pose component is used instead. We are forced to disabled URO on the individual mesh piece whenever copy pose is used.
I am facing the same issue with Metahuman head: My body simulates physics and part of the head (lower jaw) also simulates physics. Everything is fine if only the body simulates, but as soon as I enable simulation on the head it starts lagging behind and disconnects from the body. None of the above solutions work
Same issue here I’m simulating hair and main body parts and while using the copy pose from mesh lags the hair behind,none of the above solutions worked, pls help
What you want to do is make your parent/leader mesh TickGroup set to Post Physics,
then add a TickPrerequisiteComponent to force your child mesh to tick AFTER the parent mesh. Otherwise there is the chance your child mesh can tick beforehand, missing the crucial update from the parent and needing to wait until next frame.
Had a similar issue, but none of the solutions mentioned here helped. It turns out that the parent mesh was not refreshing bones as often as it should, making the animation play only for a little and then stop.
My solution was to set Visibility Based Anim Tick Option on the parent mesh from Always Tick Pose to Always Tick Pose and Refresh Bones.