def getCacheDir():
    """
    Returns the path to the cache folder.
    This folder is the Application Support folder on OS X, and the Documents Folder on Windows.
    :return unicode
    """
    if sys.platform == "win32":
        return genericSupportDir
    elif sys.platform == "darwin":
        return os.path.expanduser("~/Library/Application Support/pymclevel")
    else:
        try:
            return genericSupportDir
        except:
            return os.path.expanduser("~/.pymclevel")

    Returns the path to the cache folder.
    This folder is the Application Support folder on OS X, and the Documents Folder on Windows.
    :return unicode
    
directories.py