,Player pass through objects (already tried lots of solutions)

Hi everyone!
I’m new to Unity and I’m making the first part of the character controller using this simple script:

    private float walkSpeed = 5f;
    Animator animator;
    //private Rigidbody rb;
    void Start()
    {
        animator = GetComponent<Animator>();
        //rb = GetComponent<Rigidbody>();
    }

    void Update()
    {

        PlayerMovement();
    }

    void PlayerMovement()
    {

        float Horizontal = Input.GetAxis("Horizontal");
        float Vertical = Input.GetAxis("Vertical");
        float Jump = Input.GetAxis("Jump");
        float Fire3 = Input.GetAxis("Fire3");

        // animations

        animator.SetFloat("magnitude", Vertical);
        animator.SetFloat("Fire3", Fire3);
        animator.SetFloat("Jump", Jump);


        // position

        Vector3 newPosition = new Vector3(Horizontal, Jump * Fire3 / 2, Vertical) * walkSpeed * Time.deltaTime * (1 + Fire3);
        transform.Translate(newPosition, Space.Self);

    }

but the character (that have both capsule collider with isTrigger=false and rigid body) as you can see:

165734-cattura.png

but it still passes throw objects (and also them have box collider with isTrigger =False), no matter what.

I’ve already tried using all kinds of different functions to move the character (as MovePosition and Velocity and addForce).

Nothing seems to works, I’ve been stuck in this all day, I really don’t know what to try to know.

SOLVED: the issue was that the capsule collider of my character was very small compared to it! I’ve just enlarged it by clicking on the collider component “edit collider” and now it has no issues anymore : )