What causes this problem?

Hi,


I’ve attached an image that shows two problems I cant seem to solve.

  1. when the character walks on top of the platform, the platform slightly moves downwards through another collider.
  2. the character is able to push the platform sideways.
    Both situations should not occur.

Question is, what’s causing this and how can I solve this? (i suppose that’s two questions :)) The platform has a rigidbody (required) with a mass 100x larger than that of the character. (btw, The platform is not static as the image suggests, the collider below it is). I’ve attached a physics material to the platform where friction =1 and bounciness=0.

I’m using version 5.3.4

Any help would be appreciated

I think I found whats causing this. It’s actually a bit silly as I should have realized this earlier, but because I have my own physics on this character, what I think is happening is that the platform is trying to evaluate for the character’s collider as well as for the floor. It’s sort of squeezed into it’s correct position again.

Just set the platform to kinematic if it isnt meant to move.
If it is meant to move, then your custom character physics Im assuming is not using any physics methods like addforce or moveposition? If so, then the mass of the platform is probably irrelevant since if your character physics isnt perfect and ends up inside the platform, the platform will try to break free.

Thanks for the reply. Your assumptions are correct. I cannot use kinematic mode unfortunately (seems like the easy way out, too) so I’ll try and see if I can improve my physics (raycasting) calculations for this character.

Would freezing the platforms rigidbody rotation and position work (found on the rigidbody component), or by you not being able to use kinematic do you mean that the platform is meant to be moving?

That is not an option, as it’s possible for the platform to spawn mid-air and so it should be able to fall on top of other objects.