Refactored unit movement mechanisms.