This commit is contained in:
parent
58f19cdb9a
commit
73bb0f8ed1
@ -19,8 +19,6 @@ impl Storage<Grid2D> for KDGrid<2> {
|
|||||||
fn is_occupied(&self, position: &Grid2D) -> bool {
|
fn is_occupied(&self, position: &Grid2D) -> bool {
|
||||||
let a = self.inner.best_n_within(&[position.x as f32, position.y as f32], 0f32, 1, &taxicab_grid2).unwrap();
|
let a = self.inner.best_n_within(&[position.x as f32, position.y as f32], 0f32, 1, &taxicab_grid2).unwrap();
|
||||||
!a.is_empty()
|
!a.is_empty()
|
||||||
// let (dist_sq, _) = self.inner.nearest_one(&[position.x as f32, position.y as f32], &taxicab_grid2).unwrap();
|
|
||||||
// dist_sq == 0f32
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fn deposit(&mut self, position: &Grid2D) {
|
fn deposit(&mut self, position: &Grid2D) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user