@SuppressWarnings("rawtypes")
	public synchronized boolean clearWorldReference(String worldName)
	{
		if (regionfiles == null) { 
			plugin.getLogger().warning("Exception while removing world reference for '" + worldName + "'!");
			return false; 
		}
		if (rafField == null) { 
			plugin.getLogger().warning("Exception while removing world reference for '" + worldName + "'!"); 
			return false; 
		}

		ArrayList<Object> removedKeys = new ArrayList<Object>();
		worldName = worldName.replaceAll("/", "|");
		int Cleared = 0;

		try
		{
			for (Object o : regionfiles.entrySet())
			{
				Map.Entry e = (Map.Entry) o;
				File f = (File) e.getKey();

				String f_string = f.toString().replace("\\", "|");
				f_string = f_string.substring(2, f_string.length());

				if (f_string.startsWith(worldName))
				{
					RegionFile file = (RegionFile) e.getValue();				
					try
					{
						RandomAccessFile raf = (RandomAccessFile) rafField.get(file);

						if(raf != null && raf.length() != 0){
							raf.close();
						}

						removedKeys.add(f);
						Cleared += 1;
					}
					catch (Exception ex)
					{
						ex.printStackTrace();
					}
				}
			}
		}
		catch (Exception ex)
		{
			plugin.getLogger().warning("Exception while removing world reference for '" + worldName + "'!");
			ex.printStackTrace();
		}

		for (Object key : removedKeys)
			regionfiles.remove(key);


		return true;
	}