Whether the location on the map contains passable terrain. Is only false when the square contains impassable terrain (distinct from containing a building, for instance). LocationOffMap - the location is off the map.
(&self, location: MapLocation)
| 339 | /// |
| 340 | /// * LocationOffMap - the location is off the map. |
| 341 | pub fn is_passable_terrain_at(&self, location: MapLocation) -> Result<bool, GameError> { |
| 342 | if self.on_map(location) { |
| 343 | Ok(self.is_passable_terrain[location.y as usize][location.x as usize]) |
| 344 | } else { |
| 345 | Err(GameError::LocationOffMap)? |
| 346 | } |
| 347 | } |
| 348 | |
| 349 | /// The amount of Karbonite initially deposited at the given location. |
| 350 | /// |
no test coverage detected