Ant like robots are called Hexapods (6 legs) and Quadruped (4 legs). Each leg has 2 servos as minimum, but most developer prefer 3 servos per leg. The problem is, that arduino boards have a limit how much servos they can drive. From hardware point-of-view it is important to hide the wires inside the robot so that the construction is clean and agile.
Motion primtives are used to program the servos. Every motion primitive is mapped onto a key at the Playstation Controller. Pressing A means "move forward", pressing B means "move backwards". The predefined trajektories are created with the animation software Blender. One axis is the timescale, the other axis is the value of the servo. The combination of these diagrams results into a smooth motion of the insect robot.
Advanced control strategies are possible but are less used by amateurs. An example for a software for controlling complex tasks is PARADOCS It is not about a walking robot but about a quadcopter. A high-level planner based on a gantt chart is used to determine partial order plans.