diff --git a/README.md b/README.md index 56d5b0a..b0fe90e 100644 --- a/README.md +++ b/README.md @@ -2,9 +2,10 @@ Efficient KF3/DMM game launcher. ## Requirements -Python 3 and pip. +- Python 3 and pip. +- DMM account that owns KF3 -KF3 installed from DMM. DMM itself does not need to be running. +KF3 installed from DMM is recommended but not required. ## Instructions Download the files from this repo. Unzip them to a safe place. @@ -17,7 +18,4 @@ Input your DMM email and then password when prompted, and `yes` if you want to u If you make a mistake or you want to change login details, edit the `kfp2g.cfg` config file, or delete it to run the configuration again. -If KF3 needs to update, use `update_and_run_KF3.bat` and it will install any new updates. - -## Known issues -Retrieving launch arguments - error 308: Every once in a while, DMM games may have updated terms of service that need to be accepted. This can only be done via the official DMM app. \ No newline at end of file +If KF3 needs to update, use `update_and_run_KF3.bat` and it will install any new updates. \ No newline at end of file diff --git a/dmmBypass.py b/dmmBypass.py index 86668cf..9f6571d 100644 --- a/dmmBypass.py +++ b/dmmBypass.py @@ -32,8 +32,9 @@ if not os.path.exists(config_name): "file_path" : input('Enter full file path to KF3 .exe: ').strip('\"'), "dmm_login" : input('DMM Login (email): '), "dmm_password" : input('DMM Password: '), - "use_proxy" : input('Your login tokens will be sent through my VPN machine.\nIs that okay? (yes/no): ').lower() == "yes" + "use_proxy" : input('Your login data will be sent through my VPN.\nIs that okay? (yes/no): ').lower() == "yes" } + save_config(config_name, config) else: config = load_config(config_name) @@ -108,7 +109,7 @@ def agree_to_game_terms(game_id, use_proxy): try: print("Accepting updated game terms of use") headers = {"User-Agent": "DMMGamePlayer5-Win/5.3.12 Electron/32.1.0", "Client-App": "DMMGamePlayer5", "Client-version": "5.3.12", "Content-Type": "application/json"} - url = "" if use_proxy else "https://apidgp-gameplayer.games.dmm.com/v5/agreement/confirm/client" + url = "https://katworks.sytes.net/proxy/agreement" if use_proxy else "https://apidgp-gameplayer.games.dmm.com/v5/agreement/confirm/client" data = {"product_id":game_id,"is_notification":False,"is_myapp":False} result = requests.post(url, headers=headers, json=data) result.raise_for_status() @@ -120,16 +121,16 @@ def agree_to_game_terms(game_id, use_proxy): print("Failed to accept terms of use:", e) return False -def retrieve_launch_params(game_id, game_type, mac_addr, hdd_serial, motherboard, login_secure, login_session, use_proxy, update_game): +def retrieve_launch_params(game_id, game_type, mac_addr, hdd_serial, motherboard, login_secure, login_session, use_proxy = False, update_game = False): try: print("Retrieving launch arguments") data = {"product_id":game_id,"game_type":game_type,"game_os":"win","launch_type":"LIB","mac_address":mac_addr,"hdd_serial":hdd_serial,"motherboard":motherboard,"user_os":"win"} headers = {"User-Agent": "DMMGamePlayer5-Win/5.3.12 Electron/32.1.0", "Client-App": "DMMGamePlayer5", "Client-version": "5.3.12", "Content-Type": "application/json"} cookies = {"login_secure_id":login_secure, "login_session_id":login_session} if update_game: - url = "https://katworks.sytes.net/KF/Api/DMM/update" if use_proxy else "https://apidgp-gameplayer.games.dmm.com/v5/r2/launch/cl" + url = "https://katworks.sytes.net/proxy/launchAndUpdate" if use_proxy else "https://apidgp-gameplayer.games.dmm.com/v5/r2/launch/cl" else: - url = "https://katworks.sytes.net/KF/Api/DMM/launch" if use_proxy else "https://apidgp-gameplayer.games.dmm.com/v5/launch/cl" + url = "https://katworks.sytes.net/proxy/launch" if use_proxy else "https://apidgp-gameplayer.games.dmm.com/v5/launch/cl" result = requests.post(url, cookies=cookies, headers=headers, json=data) result.raise_for_status() result_json = result.json() @@ -222,8 +223,7 @@ def main(config): print("Starting game") args = [os.path.join(game_root_path, exec_name)] + execute_args.split() - print(args) subprocess.Popen(args, start_new_session=True) - input("Done. Press enter to exit (this will close the game)") + input("Done. Press enter to exit") main(config) \ No newline at end of file