public Node findNode(Point2D p){
        for (int i = nodes.size() - 1; i >= 0; i--){
            Node n = (Node) nodes.get(i);
            if (n.contains(p)) return n;
        }
        return null;
    }