[][src]Struct basic_pathfinding::grid::Grid

pub struct Grid { /* fields omitted */ }

Methods

impl Grid[src]

pub fn new(
    tiles: Vec<Vec<i32>>,
    walkable_tiles: Vec<i32>,
    costs: HashMap<i32, i32>,
    extra_costs: HashMap<i32, HashMap<i32, i32>>,
    unstoppable_coords: HashMap<i32, HashMap<i32, bool>>,
    unwalkable_coords: HashMap<i32, HashMap<i32, bool>>,
    grid_type: GridType
) -> Grid
[src]

pub fn is_cardinal(&self) -> bool[src]

pub fn is_hex(&self) -> bool[src]

pub fn is_intercardinal(&self) -> bool[src]

pub fn in_grid(&self, x: i32, y: i32) -> bool[src]

pub fn is_coord_stoppable(&self, x: &i32, y: &i32) -> bool[src]

pub fn is_coord_walkable(&self, x: &i32, y: &i32) -> bool[src]

pub fn get_coord_cost(&self, x: &i32, y: &i32) -> &i32[src]

Trait Implementations

impl Default for Grid[src]

impl Debug for Grid[src]

impl Serialize for Grid[src]

impl<'de> Deserialize<'de> for Grid[src]

Auto Trait Implementations

impl Send for Grid

impl Sync for Grid

Blanket Implementations

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: Deserialize<'de>, 
[src]