Hi again, I’m having a problem where a playable character in my game ends up floating above the ground after they land from a jump.
I’m not sure why happens, the character starts off fine at the start of gameplay.
Its only after the character jumps into the air & lands that problem manifests.
For some reason, crouching will fix the problem as well as switching to another character & then switching back.
Another character I have has the exact opposite problem.
Rather than the character floating above the ground after landing, instead the character will sink a couple of inches into the ground.
Like the other character, crouching or switching characters will correct the issue but I don’t want problem to exist at all.
I should also point out that the other three playable characters who all share the same basic character model, skeleton & collision capsule among each other do not have any of these issues.
Anyone have any ideas onto why is happening and how I can fix it?
I still can’t figure problem out. I’ve tried shifting the position of the mesh relative to the collision capsule on the two problem models but it doesn’t have any effect at all.
What am I supposed to be looking for specifically?
I tried experimenting with Enable Root Motion on a few animations of one of the problem characters but it didn’t change a thing.
In addition to the other models, I’m pretty sure another one I added into my project is suffering from the same problem.
Like the other two, everything seems to be fine at first, the above enemy behaves normally with no apparent issues. However, when the player character lands on the enemy from above, happens:
The enemy appears to be floating above the ground, but in actuality, its only the mesh that’s displaced.
The enemy’s collision capsule remains in the exact same place which mirrors the problem I’m having with the other characters; everything starts out fine and then something causes the mesh to become out of sync with its collision capsule. In the case of the two playable characters, that something is them landing on the ground; it doesn’t matter if they jumped or just wandered off a ledge, either way their collision capsule ends up out of sync with the model itself.
I just can’t figure out why happening to the more recent models I’ve made in Blender and have imported into Unreal Engine. In contrast, I’ve imported a number of new animations for the main character who was very first original model I made & imported into Unreal and it doesn’t have any of these issues at all, no floating above or sinking into the ground. I used the same procedure for exporting models & animations from Blender into Unreal Engine for all my models & animation but for whatever reason the first model I’ve ever imported doesn’t have any issues but the newer ones do.
And in mesh view (not character bp), do you see your characters on the ground, or they’re floating above? The same thing about animation view. If there is everything fine, so can you provide .blend file with one of broken characters and tell me your blender version? It’s just hard to say, what’s broken without that
If you open the animation and view bones (Character, Show all Bones), is the root bone moving? It shouldn’t be. That’s the first place I would look. And root motion should be off.
I went through all the character animations and the root bone isn’t moving in any of them and root motion is turned off as well.
As per SoSeriousMan’s suggestion I’ve included the Blend file for one of the problem characters for anyone to take a look at. As for the version of Blender, I don’t know as I’ve been simultaneously using an older version of Blender that I don’t the version of for all my modelling and a newer version that’s up to 3.1 for texturing.
EDIT: I removed the Blend file as it turns out the problem isn’t with the model or its animation; see the post below.
It turns out the culprit is the SetRelativeTransform event that’s used as part of the player character squishing downward a bit upon landing on the ground.
Basically the new transform location only works for the main character model and their derivatives but not for anyone else. So I guess now the question is how can I rework so that it works for all characters and not just one?