My character change its position when i start to play my scene

Hi,
i’ve created a simple scene in UE4 where inside it there is a charater that is sitting on a chair like you can see in the following picture:
image
When i start to play the scene its position change, like you can see in the following picture

image

To the character i assigned an animation importing a fbx file from the mixamo platform that is played automatically using a BlendSpace. Here you can see some setting in the Blue Print:

These are the setting for the mesh of the chacarter:

If you can suggest me how to avoid this unespected movement i will apreciate it .
Thanks for all your comments.
Best regards.

Luca

1 Like

Remove or ignore chair collision. Might just work. Otherwise the movement component of the character will attempt to immediately depenetrate from the intersecting geometry.

Hi, thank you for your answer. I did what you suggested to do i.e. i removed the collision for the chair, like you can see here:

But i still have a movement of my character when i play the game. Now if i put the character in the correct position on the chair and then i start to play the game, it still goes down a little bit.
I tried to remove collision from my character but it didn’t solve the problem.
Any idea ?
Thanks.
Luca

Could you show the scene with this flag:

ShowFlag.Collision 1

So we can see what is going on with more clarity.

image

Above, it may be difficult to see but it seems the capsule is overlapping the floor. That would bump it up as the run-time collision checks kick in.

I tried to remove collision from my character but it didn’t solve the problem.

That would not help much here, I think. The movement component only cares about what’s at the root (by default) of the actor and that element is the capsule, not the mesh.


Essentially, if you attempt to force the capsule to intersect, the movement component will eject it:

You could try to disable gravity on the movement component and collision on the capsule for as long as the character is sitting. Not sure what other interaction are there in the scene - may be a great idea, may be the worst :innocent:

Character Capsule collides with chair.

You can either disable collision for when character sits.

Or scale capsule trough script for time character sits.

Chair collision is disabled already. But scaling the capsule down is not a bad idea!

Hi,
here you can see the scene with the flag ShowFlag.Collision 1

I settet Gravity Scale to 0 to the Character Movement and now the character stayes in its position when i play the game, so i solved the problem . Thanks a lot to all !

Luca

1 Like

If it’s an NPC it does not require a movement component which contains a collision capsule. If the character is a single mesh you could just drag the animation take into the scene as just another SK asset since it does not require user input.

Actually what I want to add are NPC type assets. I followed your advice FrankieV and in this way I have the possibility to add more actors in an easier and faster way.
Thanks for the advice. I am new to UE4 so any suggestion is valuable.

Luca