need to redev the gait alg