static Color getCtryColor(String country) {
        // Special case: XXX means no one
        if (isNotACountry(country))
            country = "NAT";
        else
            country = toUpperCase(country);
        
        
        Color ret = ctryColorCache.get(country);
        if (ret == null) {
            
            String filename = countries.getString(country);
            if (!filename.startsWith("common"))
                filename = "common/" + filename.toLowerCase();
            filename = Main.filenameResolver.resolveFilename(filename);
            
            final GenericObject countryDef = EUGFileIO.load(filename, settings);
            
            if (countryDef == null) {
                System.err.println("No country definition file found for " + country + ".");
                System.err.println("Expected to find it in " + filename);
                return COLOR_NO_CTRY_DEF;
            }
            
            final GenericList color = countryDef.getList("color");
            
            if (color == null) {
                System.err.println("color for " + country + " is null");
                return COLOR_NO_CTRY_DEF;
            }
            
            final int red = Math.min(Integer.parseInt(color.get(0)), 255);
            final int green = Math.min(Integer.parseInt(color.get(1)), 255);
            final int blue = Math.min(Integer.parseInt(color.get(2)), 255);
            
            ret = new Color(red, green, blue);
            
            ctryColorCache.put(country, ret);
        }
        return ret;
    }