UNET Players are movable on collision

Hi guys,

On my multiplayer game, when a player enter in a collision on another player, he can move him. Do you know how to resolve this problem ? I’m trying to create a temporary debug with a boolean with OnCollision(Enter/Stay) and OnCollisionExit. It’s the only way?

Best regards,

You want a method other than Collision check? Well , what I’ll do in this is make a float variable ‘distance’.
Then equal that to Vector3.Distance(); and in parameters , put my player’s position as point A and enemy’s position as point B.
Then I’ll check that if distance <= 1f or so depending upon the models , and execute the debug.log statement on that. If distance > 1f , execute something else. Isn’t it a good alternative? :slight_smile:

No, when a player enter in collision, he is moving the other player… I don’t know how to solve this…!