public static boolean pointInside(Positioned other, double x, double y, boolean notOnTheEdge)
    {
        if (notOnTheEdge)
            return  x > other.leftBorder() && x < other.rightBorder() &&
                y > other.topBorder() && y < other.bottomBorder();
        else
            return  x >= other.leftBorder() && x <= other.rightBorder() &&
                y >= other.topBorder() && y <= other.bottomBorder();
    }