pub fn tile_in_bounds(&self, tile_pos: IVec2) -> bool {
        let (min, max) = match self.centered {
            true => {
                let min = -self.tile_count.as_ivec2() / 2;
                let max = min + self.tile_count.as_ivec2();
                (min, max)
            }
            false => (IVec2::ZERO, self.tile_count.as_ivec2()),
        };

        let above_min = tile_pos.cmpge(min);
        let below_max = tile_pos.cmplt(max);
        above_min.all() && below_max.all()
    }
/// Whether or not the given tile is in the bounds of the grid.
Whether or not the given tile is in the bounds of the grid.
Whether or not the given tile is in the bounds of the grid .
pub fn tile_in_bounds(&self, tile_pos: IVec2) -> bool {
        let (min, max) = match self.centered {
            true => {
                let min = -self.tile_count.as_ivec2() / 2;
                let max = min + self.tile_count.as_ivec2();
                (min, max)
            }
            false => (IVec2::ZERO, self.tile_count.as_ivec2()),
        };
        let above_min = tile_pos.cmpge(min);
        let below_max = tile_pos.cmplt(max);
        above_min.all() && below_max.all()
    }
pub fn tile_in_bounds ( & self , tile_pos : IVec2 ) -> bool { let ( min , max ) = match self . centered { true => { let min = - self . tile_count . as_ivec2 ( ) / 2 ; let max = min + self . tile_count . as_ivec2 ( ) ; ( min , max ) } false => ( IVec2 :: ZERO , self . tile_count . as_ivec2 ( ) ) , } ; let above_min = tile_pos . cmpge ( min ) ; let below_max = tile_pos . cmplt ( max ) ; above_min . all ( ) && below_max . all ( ) }
Whether or not the given tile is in the bounds of the grid.
Whether or not the given tile is in the bounds of the grid .
&self
tile_pos
IVec2
&self
tile_pos
IVec2