I'm not sure what you're trying to do, you don't need
to change the value of "ball_gravity" every frame, the
ball model will glide on the ground automatically and
it still move smoothly when it land as I tested with my
latest A7.com

I see that you're still using "time" not "time_step", it may
be the problem of c_move in old A6 version.

Maybe you could try move_friction :

Code:
while(1)
{
    ball_move.x = (key_d - key_a) * 5 * time;
    move_friction = 0;
    c_move(....blah..blah)
    wait(1);
}