public static bool IsNear(int dValueToHave, int dValueToCompare, int dist) { return Math.Abs(dValueToHave - dValueToCompare) <= Math.Abs(dist); }