colli: fixed calculation of moving direction