Skip to content

Commit

Permalink
Change reconnect message
Browse files Browse the repository at this point in the history
  • Loading branch information
anthony5301 authored Jan 16, 2024
1 parent 9aca88d commit b2f439e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion game.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ def check_failed_to_connect_window(self) -> bool:
print(" Found \"Failed to Connect\" window, trying to exit and reconnect")
if reconnect_button := win32gui.FindWindowEx(hwnd, 0, "Button", None):
if cancel_button := win32gui.FindWindowEx(hwnd, reconnect_button, "Button", None):
print(f"{win32gui.GetWindowText(cancel_button)} button found.")
print(" Exiting the game.")
win32gui.SendMessage(cancel_button, BM_CLICK, 0, 0)
return True
print(" Cancel button not found.")
Expand Down

0 comments on commit b2f439e

Please sign in to comment.