pub fn make_index(&self, point: Vec2) -> Option<usize> {
        let x = coord::to_index(point.x);
        let y = coord::to_index(point.y);
        if x >= self.width || self.curr.len() / self.width <= y {
            None
        } else {
            Some(y * self.width + x % self.width)
        }
    }
/// Makes an index from a coordinate.
Makes an index from a coordinate.
Makes an index from a coordinate .
pub fn make_index(&self, point: Vec2) -> Option<usize> {
        let x = coord::to_index(point.x);
        let y = coord::to_index(point.y);
        if x >= self.width || self.curr.len() / self.width <= y {
            None
        } else {
            Some(y * self.width + x % self.width)
        }
    }
pub fn make_index ( & self , point : Vec2 ) -> Option < usize > { let x = coord :: to_index ( point . x ) ; let y = coord :: to_index ( point . y ) ; if x >= self . width || self . curr . len ( ) / self . width <= y { None } else { Some ( y * self . width + x % self . width ) } }
Makes an index from a coordinate.
Makes an index from a coordinate .
&self
point
Vec2
&self
point
Vec2