Create costpath