Avoid the obstacles. Sorry the second half isn't finished. I'll post an ubdated version in a day or so.