Why does my player walk through walls?

Hi

I’m not sure how to explain this but my player is not stopping completely when he walks into walls. He can get half of his body through the wall before being stopped.

Here’s some general information that could be useful (?).


(That is the player wielding a torch just chilling, WITH A "%# WALL IN HIS HEAD)

Player script

var speed = 3.0;
var rotateSpeed = 3.0;
var bullet : GameObject;

function Update ()
{
if(Input.GetKeyDown("space")) 
   { 
      var the_bullet = Instantiate(bullet); 
      the_bullet.transform.position = transform.position; 
      the_bullet.transform.rotation = transform.rotation; 
   }
      var controller : CharacterController = GetComponent(CharacterController);

      // Rotate around y - axis
      transform.Rotate(0, Input.GetAxis ("Horizontal") * rotateSpeed, 0);

      // Move forward / backward
      var forward = transform.TransformDirection(Vector3.forward);
      var curSpeed = speed * Input.GetAxis ("Vertical");
      controller.SimpleMove(forward * curSpeed);
}

@script RequireComponent(CharacterController)

How do I fix this? Please help me!

Thanks in advance,
Redoxe

I cant see anything in your screenshot.

Did you double check your collider settings? Looks like one collider is to small (wall or character)

Thanks a lot! It’s working now, changed the Skin Width in the Character Controller settings.

I’d like to know if you can make a particle system (fireball) stop when it hits walls. I’ve tried putting it into a prefab together with a cube that has a box collider. Not even the box stopped.

Does anyone know how to fix this?