Don't grind/rpg with objects more than 5y away if master is not resting

This commit is contained in:
郑佩茹
2023-03-30 11:55:43 -06:00
parent 47b13bf73a
commit 2f4d3276e8

View File

@@ -303,7 +303,7 @@ bool ChooseRpgTargetAction::isFollowValid(Player* bot, WorldPosition pos)
return true; return true;
} }
if (inDungeon && realMaster == master && distance > 5.0f) if ((inDungeon || !master->HasPlayerFlag(PLAYER_FLAGS_RESTING)) && realMaster == master && distance > 5.0f)
return false; return false;
if (!master->isMoving() && distance < 25.0f) if (!master->isMoving() && distance < 25.0f)