Skip to content

Instantly share code, notes, and snippets.

@terremoth
Last active April 6, 2024 03:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save terremoth/43b8f8a03a910b19b64d8f22dbd66587 to your computer and use it in GitHub Desktop.
Save terremoth/43b8f8a03a910b19b64d8f22dbd66587 to your computer and use it in GitHub Desktop.
Bot DFM
import pyautogui
import random
import time
import keyboard
screenWidth, screenHeight = pyautogui.size()
def random_sleep():
return random.uniform(0.625, 1.555)
while True:
if keyboard.is_pressed('q'):
print("exiting loop")
break
pyautogui.moveTo(random.randint(286, 290), random.randint(540, 545))
pyautogui.click()
time.sleep(random_sleep())
pyautogui.moveTo(random.randint(246, 253), random.randint(946, 953))
# pyautogui.moveTo(random.randint(240, 250), random.randint(830, 860))
pyautogui.click()
time.sleep(random_sleep())
pyautogui.moveTo(random.randint(1137, 1143), random.randint(619, 624))
pyautogui.click()
time.sleep(random_sleep())
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment