Rigidbody weird effect.

Hello guys, I have recently started digging into unity. I want to make a small project where you walk around a box and shoot things, but I’m getting some undesired effects.
When I press play and walk into a wall, the object starts flying everywhere.
I know that doesn’t really help, so I have attached a link to the project
https://www.dropbox.com/s/5ydegx5esg2ovkc/The%20box.zip?dl=0

Edit:
The object is the player (just the camera), I’ve made it move with WASD. Removing rigidbody makes the object go through the walls setting iskinemtaic to the object makes it go through walls. Changing the weight doesn’t remove the problem.

I have done some testing and found out that the effect is not present when I have the script for mouselook disabled

The script was not made by me, but I can not find anything that would effect its position.

I’m on my phone so I can’t download the project.

If the object in question doesn’t need to move you can take off its rigid body and then it won’t get pushed by the player. Or you can set the rigid body to “iskinematic”. Then it won’t be pushed by physics forces (usually just used for the player object, not static objects). A third option is to increase an objects weight.

If you need a different solution/info let me know.

@JustRoss

You might be a bit mad at the answer that I found for you…

Go into the Player(Camera) in the hierarchy → Rigidbody → Constraints → And Click Freeze rotation in the X, Y and Z axis

Found out the problem was infact in the mouselook script, ive replaced it with another one and it works.
If anyone can tell me what was causing it inside the script, that would be great for future knowledge, but you don’t have to.