Two GameObjects "Pushing" eachother

Hello,

I’ve got an issue: I’ve got a player and an enemy in a top down dungeon crawler game.

Whenever the enemy runs against the player, the player gets pushed backwards. The same happens when the player runs against the enemy. Is there a way to prevent this from happening? I want both the enemy and the player to be “unpushable” when running up against eachother.

I already tried playing with the mass/drag/angular drag of both objects, but it didn’t help. If I increase the mass of the enemy by for example 100, it is obvious that the enemy wont be pushed backwards because he is too heavy. But instead pushing the player will become even easier because the player weighs nothing compared to the enemy.

Thanks in advance

You should use the “Character controller” component for both, your player, and your enemy, that should prevent the physics/related interaction and at the same time avoiding the “ghost” effect that you’re complaining about.

Don’t just use simple colliders for that, or you’ll enable the use of phisics between them.