Refactor WorldPos, WindowsPos done

This commit is contained in:
Jan Mrna
2025-10-04 16:54:29 +02:00
committed by Mrna
parent 47977d9979
commit 8a49c12909
13 changed files with 89 additions and 61 deletions

View File

@@ -11,7 +11,7 @@ namespace pathfinder {
float GBFS::Heuristic(const TilePos& a, const TilePos& b)
{
return static_cast<float>(std::abs(a.x- b.x) + std::abs(a.y - b.y));
return static_cast<float>(std::abs(a.x() - b.x()) + std::abs(a.y() - b.y()));
}
Path GBFS::CalculatePath(WorldPos start_world, WorldPos end_world)