Fixed issue with going backwards. Better movement algorithm.