diff -r 55c8267c933f -r aefc131bf5ce src/yapf/yapf_common.hpp --- a/src/yapf/yapf_common.hpp Thu Jan 11 13:41:16 2007 +0000 +++ b/src/yapf/yapf_common.hpp Mon Jan 15 20:14:06 2007 +0000 @@ -138,8 +138,8 @@ * adds it to the actual cost from origin and stores the sum to the Node::m_estimate */ inline bool PfCalcEstimate(Node& n) { - int dx = abs(TileX(n.GetTile()) - TileX(m_destTile)); - int dy = abs(TileY(n.GetTile()) - TileY(m_destTile)); + int dx = delta(TileX(n.GetTile()), TileX(m_destTile)); + int dy = delta(TileY(n.GetTile()), TileY(m_destTile)); assert(dx >= 0 && dy >= 0); int dd = min(dx, dy); int dxy = abs(dx - dy);