Increasing Reliability of Legged Robots in the Presence of Uncertainty