if(Thread.interrupted()) { done(); return; }
    private void loadMechData() {        Vector vMechs = new Vector();        Set sKnownFiles = new HashSet();        long lLastCheck = 0;        entityVerifier = new EntityVerifier(new File(CONFIG_FILENAME));        hFailedFiles = new Hashtable();        EquipmentType.initializeTypes(); // load master equipment lists        loadReport.append("\n");        loadReport.append("Reading unit files:\n");        // check the cache        try {            if (CACHE.exists() && CACHE.lastModified() >= megamek.MegaMek.TIMESTAMP) {                loadReport.append("  Reading from unit cache file...\n");                lLastCheck = CACHE.lastModified();                BufferedReader br = new BufferedReader(new FileReader(CACHE));                String s;                while ((s = br.readLine()) != null) {                    MechSummary ms = new MechSummary();                    // manually do a string tokenizer.  Much faster                    int nIndex1 = s.indexOf(SEPARATOR);                    ms.setName(s.substring(0, nIndex1));                    int nIndex2 = s.indexOf(SEPARATOR, nIndex1 + 1);                    ms.setChassis(s.substring(nIndex1 + 1, nIndex2));                    nIndex1 = nIndex2;                    nIndex2 = s.indexOf(SEPARATOR, nIndex1 + 1);                    ms.setModel(s.substring(nIndex1 + 1, nIndex2));                    nIndex1 = nIndex2;                    nIndex2 = s.indexOf(SEPARATOR, nIndex1 + 1);                    ms.setUnitType(s.substring(nIndex1 + 1, nIndex2));                    nIndex1 = nIndex2;                    nIndex2 = s.indexOf(SEPARATOR, nIndex1 + 1);                    ms.setSourceFile(new File(s.substring(nIndex1 + 1, nIndex2)));                    nIndex1 = nIndex2;                    nIndex2 = s.indexOf(SEPARATOR, nIndex1 + 1);                    ms.setEntryName(s.substring(nIndex1 + 1, nIndex2));                    // have to translate "null" to null                    if (ms.getEntryName().equals("null")) {                        ms.setEntryName(null);                    }                    nIndex1 = nIndex2;                    nIndex2 = s.indexOf(SEPARATOR, nIndex1 + 1);                    ms.setYear(Integer.parseInt(s.substring(nIndex1 + 1, nIndex2)));                    nIndex1 = nIndex2;                    nIndex2 = s.indexOf(SEPARATOR, nIndex1 + 1);                    ms.setType(Integer.parseInt(s.substring(nIndex1 + 1, nIndex2)));                    nIndex1 = nIndex2;                    nIndex2 = s.indexOf(SEPARATOR, nIndex1 + 1);                    ms.setTons(Integer.parseInt(s.substring(nIndex1 + 1, nIndex2)));                    nIndex1 = nIndex2;                    nIndex2 = s.indexOf(SEPARATOR, nIndex1 + 1);                    ms.setBV(Integer.parseInt(s.substring(nIndex1 + 1, nIndex2)));                    nIndex1 = nIndex2;                    nIndex2 = s.indexOf(SEPARATOR, nIndex1 +1);                    ms.setLevel(s.substring(nIndex1 + 1, nIndex2));                    nIndex1 = nIndex2;                    nIndex2 = s.indexOf(SEPARATOR, nIndex1 +1);                    ms.setCost(Integer.parseInt(s.substring(nIndex1 + 1,nIndex2)));                    ms.setCanon(s.substring(nIndex2+1).equals("T")? true : false);                    // Verify that this file still exists and is older than                    //  the cache.                    File fSource = ms.getSourceFile();                    if (fSource.exists() && fSource.lastModified() < lLastCheck) {                        vMechs.addElement(ms);                        sKnownFiles.add(ms.getSourceFile().toString());                        cacheCount++;                    }                }            }        } catch (Exception e) {            loadReport.append("  Unable to load unit cache: ")                .append(e.getMessage()).append("\n");        }        // load any changes since the last check time        boolean bNeedsUpdate = loadMechsFromDirectory(vMechs, sKnownFiles, lLastCheck, ROOT);        // convert to array        m_data = new MechSummary[vMechs.size()];        vMechs.copyInto(m_data);        // store map references        for (int x = 0; x < m_data.length; x++) {            m_nameMap.put(m_data[x].getName(), m_data[x]);        }        // save updated cache back to disk        if (bNeedsUpdate) {            try {                saveCache();            } catch (Exception e) {                loadReport.append("  Unable to save mech cache\n");            }        }        loadReport.append(m_data.length).append(" units loaded.\n");        if (hFailedFiles.size() > 0) {            loadReport.append("  ").append(hFailedFiles.size())                .append(" units failed to load...\n");        }        /*        Enumeration failedUnits = hFailedFiles.keys();        Enumeration failedUnitsDesc = hFailedFiles.elements();        while (failedUnits.hasMoreElements()) {            loadReport.append("    ").append(failedUnits.nextElement())                .append("\n");            loadReport.append("    --")                .append(failedUnitsDesc.nextElement()).append("\n");        }        */        System.out.print(loadReport.toString());        done();    }