Skip to content

Commit ea4b399

Browse files
authored
Update Utilities.py
Fixed bug with bhop
1 parent fda78e5 commit ea4b399

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Utils/Utilities.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# Last update 2022,Jan,10
1010

1111

12-
versioncontrol = "2.5"
12+
versioncontrol = "2.6"
1313

1414

1515
def GetWindowText(handle, length=100):
@@ -49,7 +49,7 @@ def strtobool(string):
4949

5050

5151
def is_key(string):
52-
if keyboard.is_modifier(string) or (string.isalpha() and len(string) == 1):
52+
if keyboard.is_modifier(string) or (string.isalpha() and len(string) == 1) or string == "space":
5353
return True
5454
else:
5555
return False
@@ -72,5 +72,5 @@ def is_pressed(key):
7272
else:
7373
return mouse.is_pressed(key)
7474
else:
75-
MessageBox = ctypes.windll.user32.MessageBoxW(0, "Not a valid Key", "Config Error", 0)
75+
MessageBox = ctypes.windll.user32.MessageBoxW(0, f"{key.upper()} is not a valid Key", "Config Error", 0)
7676
return False

0 commit comments

Comments
 (0)