diff --git a/mpaths.py b/mpaths.py index 96589e4..69d723a 100644 --- a/mpaths.py +++ b/mpaths.py @@ -3,7 +3,7 @@ import traceback try: - hkey = winreg.OpenKey(winreg.HKEY_LOCAL_MACHINE, "SOFTWARE\WOW6432Node\Valve\Steam") + hkey = winreg.OpenKey(winreg.HKEY_LOCAL_MACHINE, r"SOFTWARE\WOW6432Node\Valve\Steam") except Exception as exception: hkey = None with open(os.path.join(os.getcwd(), 'logs\\registry.txt'), 'w') as file: @@ -23,9 +23,8 @@ # when dota2 is not inside Steam folder then set new steam directory from 'dota2path_minify.txt # this text file is created and set by the user in validatefiles.py during startup -if not os.path.exists(os.path.join(steam_dir, 'common\dota 2 beta\game\bin\win64\dota2.exe')): - documents = os.path.join(os.path.expanduser('~'), 'Documents') - path_file = os.path.join(documents, 'dota2path_minify.txt') +if not os.path.exists(os.path.join(steam_dir, 'steamapps\\common\\dota 2 beta\\game\\bin\\win64\\dota2.exe')): + path_file = os.path.join(os.getcwd(), 'dota2path_minify.txt') # make sure the text file exists if not os.path.exists(path_file):