Cant get sphere to stop.

I have been playing around trying to get a sphere to just stop after is slows down, I have tried:

rb.velocity = Vector3.zero;
rb.angularVelocity = Vector3.zero;

But that does not seem to be working. It slows it down to a crawl but the sphere still moves for quite some time.
Any ideas?

Mind posting the rest of your code that affects the sphere? The code you put above should be working. Is the ball not on a flat surface?

usually i did this:

        rb.isKinematic = true;
        rb.isKinematic = false;

don’t know about it’s performance though.

Here is the full class:

    void Update () {
        if (gameStates.playerTurn == playerNum && !playerStates.takingShot)
        {
            Debug.DrawLine(transform.position, transform.forward, Color.green);
            InputManager();
        }

        if (playerStates.settingPower)
            SetPower();

        if (playerStates.takingShot)
        {
            if (CheckIfStoped())
            {
                rb.velocity = Vector3.zero;
                rb.angularVelocity = Vector3.zero;
                playerStates.takingShot = false;
                playerStates.isStoped = true;
                gameController.EndTurn();
            }

        }


       
    }

    void InputManager()
    {
        if (Input.GetAxis("Horizontal") != 0)
        {
            transform.Rotate(Vector3.up, Input.GetAxis("Horizontal") * Time.deltaTime * 100);
        }
        if (Input.GetButtonDown("Fire1"))
        {

            if (playerStates.settingPower)
            {
                AddForce(powerSlider.value);
                playerStates.settingPower = false;
                playerStates.takingShot = true;
            }
           
            if (!playerStates.takingShot)
            {
                playerStates.settingPower = true;
            }
        }
    }

    void SetPower()
    {

        if (sliderMovingUp)
            powerSlider.value += gameController.powerSlideSpeed;
        if (powerSlider.value == powerSlider.maxValue)
            sliderMovingUp = false;

        if (!sliderMovingUp)
            powerSlider.value -= gameController.powerSlideSpeed;
        if (powerSlider.value == powerSlider.minValue)
            sliderMovingUp = true;
       
    }

    void AddForce(float power)
    {
        rb.AddRelativeForce(Vector3.forward * speedMultiplyer * power, ForceMode.Impulse);
        playerStates.isStoped = false;
    }

    bool CheckIfStoped()
    {
        if (rb.velocity.magnitude == 0)
            return true;
        else
            return false;
    }

does CheckIfStoped ever actually return true? if it never returns true, then you will never run the code that stops the ball. This is where debug.logging would come in handy to see what is and isnt running.

You should also not compare float values with real values like 0 due to floating point imprecision. That is why there is the approximate method

maybe try this instead

    bool CheckIfStoped()
    {
        return (rb.velocity.magnitude < .1f);
    }

It is definitely triggering. I tried your change, but it did not change the behavior.