@Override
	public Faction getFaction(String factionID)
	{
		if(factionID==null)
			return null;
		Faction F=factionSet.get(factionID.toUpperCase());
		if((F==null)&&(!factionID.toLowerCase().endsWith(".ini")))
		{
			F=getFaction(factionID+".ini");
		}
		if(F!=null)
		{
			if(F.isDisabled())
				return null;
			if(!F.amDestroyed())
				return F;
			factionSet.remove(F.factionID().toUpperCase());
			Resources.removeResource(F.factionID());
			return null;
		}
		final CMFile f=new CMFile(Resources.makeFileResourceName(makeFactionFilename(factionID)),null,CMFile.FLAG_LOGERRORS);
		if(!f.exists())
			return null;
		final StringBuffer buf=f.text();
		if((buf!=null)&&(buf.length()>0))
		{
			return buildFactionFromXML(buf, factionID);
		}
		return null;
	}