add bridge tile for better bridge pathfinding

This commit is contained in:
Isse 2023-04-12 10:57:43 +02:00
parent b40e2b4fe4
commit 9c30d2018d
3 changed files with 3 additions and 2 deletions

View File

@ -61,7 +61,7 @@ fn path_in_site(start: Vec2<i32>, end: Vec2<i32>, site: &site2::Site) -> PathRes
TileKind::Empty => 3.0,
TileKind::Hazard(_) => 50.0,
TileKind::Field => 8.0,
TileKind::Plaza | TileKind::Road { .. } | TileKind::Path => 1.0,
TileKind::Plaza | TileKind::Road { .. } | TileKind::Path | TileKind::Bridge => 1.0,
TileKind::Building
| TileKind::Castle

View File

@ -1067,7 +1067,7 @@ impl Site {
});
site.blit_aabr(aabr, Tile {
kind: TileKind::Building,
kind: TileKind::Bridge,
plot: Some(plot),
hard_alt: None,
});

View File

@ -191,6 +191,7 @@ pub enum TileKind {
Keep(KeepKind),
Gate,
GnarlingFortification,
Bridge,
}
#[derive(Clone, PartialEq)]