Fixed the bug about the error in convrtion of floating velocities to integer