Skip to content
Permalink
master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
import pyautogui as pya
import numpy as np
pya.FAILSAFE = True
#find screen dimensions
x,y = pya.size()
while pya.FAILSAFE == True:
#determine a random point on the screen
xnew = np.random.randint(0,x)
ynew = np.random.randint(0,y)
#smoothly move the cursor to that point
pya.moveTo(xnew,ynew,duration=3,tween=pya.easeInOutQuad)
#pause
pya.PAUSE = 5