Changed the way direction of a robot is controlled