implementing a bugout routine