Skip to content

Commit

Permalink
fix mouse origin tracking
Browse files Browse the repository at this point in the history
  • Loading branch information
Matthew Stream-PC committed Nov 23, 2022
1 parent c4f4d44 commit b84d445
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pyclashbot/memu/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ def click(x, y, duration=1, max_attempts=3):
duration (int, optional): Duration of the click. Defaults to 1.
max_attempts (int, optional): Maximum amount of attempts to click the given coordinate. Defaults to 3. Set to less than 1 for infinite attempts.
"""
origin = ahk.mouse_position()
origin = ahk.mouse_position
duration = min(10, duration) # 10 seconds max (ahk limitation)
speed = duration * 10 # speed for ahk (0-100)

Expand Down

0 comments on commit b84d445

Please sign in to comment.