According to your code, you activate the motion simulation for one tick every x seconds. By comparison, how far would a car go if you hit the accelerator for 0.016 seconds?
Pathfinding also works outside the visible area, but not outside the layout, which you probably mean. In this case, you can also enlarge your layout and fix the camera in the middle. Then you can also spawn opponents out of the field of view and move them with pathfinding.