e.printStackTrace();
    public boolean loadMap(String file) {        try {            MapReader mr = null;            if (file.endsWith(".tmx")) {                // Override, so people can't overtake our format                mr = new XMLMapTransformer();            } else {                mr = (MapReader)pluginLoader.getReaderFor(                        file.substring(file.lastIndexOf('.') + 1));            }            if (mr != null) {                setCurrentMap(mr.readMap(file));                updateRecent(file);                return true;            } else {                JOptionPane.showMessageDialog(appFrame,                        "Unsupported map format", "Error while loading map",                        JOptionPane.ERROR_MESSAGE);            }        } catch (IOException e) {            JOptionPane.showMessageDialog(appFrame,                    e.getMessage() + (e.getCause() != null ? "\nCause: "+e.getCause().getMessage() : ""), "Error while loading map",                    JOptionPane.ERROR_MESSAGE);            e.printStackTrace();        } catch (Exception e) {            //e.printStackTrace();            JOptionPane.showMessageDialog(appFrame,                    "Error while loading " + file + ": " +                    e.getMessage(), "Error while loading map",                    JOptionPane.ERROR_MESSAGE);            e.printStackTrace();        }        return false;    }