sorry - swapping from rustfmt to prettier-rust

This commit is contained in:
Llywelwyn 2023-08-23 01:22:09 +01:00
parent 281396f9ce
commit c2c7e0bd52
93 changed files with 2797 additions and 2021 deletions

View file

@ -1,4 +1,4 @@
use super::{BuilderMap, MetaMapBuilder, Rect, TileType};
use super::{ BuilderMap, MetaMapBuilder, Rect, TileType };
use rltk::RandomNumberGenerator;
pub struct RoomCornerRounder {}
@ -23,13 +23,13 @@ impl RoomCornerRounder {
if x > 0 && build_data.map.tiles[idx - 1] == TileType::Wall {
neighbour_walls += 1;
}
if y > 0 && build_data.map.tiles[idx - w as usize] == TileType::Wall {
if y > 0 && build_data.map.tiles[idx - (w as usize)] == TileType::Wall {
neighbour_walls += 1;
}
if x < w - 2 && build_data.map.tiles[idx + 1] == TileType::Wall {
neighbour_walls += 1;
}
if y < h - 2 && build_data.map.tiles[idx + w as usize] == TileType::Wall {
if y < h - 2 && build_data.map.tiles[idx + (w as usize)] == TileType::Wall {
neighbour_walls += 1;
}
if neighbour_walls == 2 {