BallReset() called but not resetting ball

Hey guys,
It’s been awhile but I’m back trying to finish Bowl Master. For some reason my ResetBall() function is getting called (according to Debug.log) but is not resetting the ball. I’m using Unity 2017.1 but I can’t imagine that having a difference in this case. Here is my code:

public void Reset()
{
    Debug.Log("Called Reset");
    transform.position = startPosition;
    inPlay = false;
    rb.velocity = Vector3.zero;
    rb.angularVelocity = Vector3.zero;
    rb.useGravity = false;
}

and separately the PinSetter script has the Reset code here (but I already mentioned it was working):

private void PinsHaveSettled()
{
    ball.Reset();
    ballEnteredBox = false;
    lastStandingCount = -1;
    pinCountText.color = Color.green;
}

Discoverd the culprit was multiple balls in the scene. Removed them and the ball resets just fine.

1 Like