diff --git a/src/face_crawler.rs b/src/face_crawler.rs index 5cdc1e1..9faf38a 100644 --- a/src/face_crawler.rs +++ b/src/face_crawler.rs @@ -1,18 +1,18 @@ use crate::physics::Body; -use crate::model_physics::{FEV,MeshQuery,DirectedEdge,MinkowskiMesh,MinkowskiFace,MinkowskiDirectedEdge,MinkowskiVert}; +use crate::model_physics::{GigaTime,FEV,MeshQuery,DirectedEdge,MinkowskiMesh,MinkowskiFace,MinkowskiDirectedEdge,MinkowskiVert}; use strafesnet_common::integer::{Time,Fixed,Ratio}; #[derive(Debug)] enum Transition{ Miss, - Next(FEV,Ratio,Fixed<4,128>>), - Hit(F,Ratio,Fixed<4,128>>), + Next(FEV,GigaTime), + Hit(F,GigaTime), } type MinkowskiFEV=FEV; type MinkowskiTransition=Transition; - fn next_transition(fev:&MinkowskiFEV,body_time:Ratio,Fixed<4,128>>,mesh:&MinkowskiMesh,body:&Body,mut best_time:Ratio,Fixed<4,128>>)->MinkowskiTransition{ + fn next_transition(fev:&MinkowskiFEV,body_time:GigaTime,mesh:&MinkowskiMesh,body:&Body,mut best_time:GigaTime)->MinkowskiTransition{ //conflicting derivative means it crosses in the wrong direction. //if the transition time is equal to an already tested transition, do not replace the current best. let mut best_transtition=MinkowskiTransition::Miss; @@ -102,7 +102,7 @@ type MinkowskiTransition=Transition{ Miss(FEV), - Hit(F,Ratio,Fixed<4,128>>), + Hit(F,GigaTime), } type MinkowskiCrawlResult=CrawlResult; pub fn crawl_fev(mut fev:MinkowskiFEV,mesh:&MinkowskiMesh,relative_body:&Body,start_time:Time,time_limit:Time)->MinkowskiCrawlResult{