Browse Source

Use WalkingDistance in TalkToTowner

pull/2113/head
Vladimir Olteanu 5 years ago committed by Anders Jenbo
parent
commit
cc9783b8d9
  1. 3
      Source/towners.cpp

3
Source/towners.cpp

@ -899,8 +899,7 @@ void TalkToTowner(PlayerStruct &player, int t)
{
auto &towner = towners[t];
Point distance = player.position.tile - towner.position;
if (abs(distance.x) >= 2 || abs(distance.y) >= 2)
if (player.position.tile.WalkingDistance(towner.position) >= 2)
return;
if (pcurs >= CURSOR_FIRSTITEM) {

Loading…
Cancel
Save