im making a basic game were you have to get past lodes of levels as a ball that has to dodge stuff and stay on the platforms i have a basic moving code but i want to make the ball roll like a ball when it moves. can someone help me please with some. this is my moving code so far
var speed = 3.0;
var rotateSpeed = 3.0;
function Update ()
{
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);
}