Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import time
- import random
- import pyautogui
- import keyboard
- import mouse
- starter = 0
- black = 0
- def change():
- global starter
- global black
- first_cord, second_cord = pyautogui.position()
- if pyautogui.pixelMatchesColor(first_cord, second_cord, (0, 0, 0), tolerance=20) is True:
- black = 1
- print('Stay Safe!')
- elif pyautogui.pixelMatchesColor(663, 1079, (164, 206, 239), tolerance=20) is not True:
- time.sleep(1)
- pyautogui.press('/')
- time.sleep(1)
- pyautogui.moveTo(668, 1058)
- time.sleep(1)
- pyautogui.click()
- time.sleep(1)
- pyautogui.moveTo(1781, 924)
- time.sleep(1)
- pyautogui.click()
- time.sleep(1)
- pyautogui.press('esc')
- time.sleep(1)
- print('we have done it!')
- starter += 1
- else:
- return
- while True:
- time.sleep(20)
- change()
- print('Restart #: '+ str(starter))
- if starter == 30 or black == 1:
- breakimport time
- import random
- import pyautogui
- import keyboard
- import mouse
- starter = 0
- black = 0
- def change():
- global starter
- global black
- first_cord, second_cord = pyautogui.position()
- if pyautogui.pixelMatchesColor(first_cord, second_cord, (0, 0, 0), tolerance=20) is True:
- black = 1
- print('Stay Safe!')
- elif pyautogui.pixelMatchesColor(663, 1079, (164, 206, 239), tolerance=20) is not True:
- time.sleep(1)
- pyautogui.press('/')
- time.sleep(1)
- pyautogui.moveTo(668, 1058)
- time.sleep(1)
- pyautogui.click()
- time.sleep(1)
- pyautogui.moveTo(1781, 924)
- time.sleep(1)
- pyautogui.click()
- time.sleep(1)
- pyautogui.press('esc')
- time.sleep(1)
- print('we have done it!')
- starter += 1
- else:
- return
- while True:
- time.sleep(20)
- change()
- print('Restart #: '+ str(starter))
- if starter == 30 or black == 1:
- break
Add Comment
Please, Sign In to add comment