diff --git a/src/face_crawler.rs b/src/face_crawler.rs index 3081eb5..74440e6 100644 --- a/src/face_crawler.rs +++ b/src/face_crawler.rs @@ -108,12 +108,14 @@ pub enum CrawlResult{ } pub fn crawl_fev(mut fev:FEV,mesh:&impl MeshQuery,relative_body:&Body,start_time:Time,time_limit:Time)->CrawlResult{ let mut time=start_time; - for _ in 0..10{ + for _ in 0..20{ match next_transition(&fev,time,mesh,relative_body,time_limit){ Transition::Miss=>return CrawlResult::Miss(fev), Transition::Next(next_fev,next_time)=>(fev,time)=(next_fev,next_time), Transition::Hit(face,time)=>return CrawlResult::Hit(face,time), } } - panic!("Too many iterations!"); + //TODO: fix all bugs + println!("Too many iterations! Using default behaviour instead of crashing..."); + CrawlResult::Miss(fev) }