Move Servo Until Criteria is Met

How would I make a servo turn (when criteria1 is met) until it reaches 180 OR criteria2 is met and move back to 0 when criteria1 is false? I have other code in my loop so I would like not to use delay. I have 5 servos that need to move at the same time.

Have a look at how millis() is used to manage timing without blocking in Several things at a time. It includes a function to control a servo