Fixed the speed being set to -Infinity