Skip to main content

automate an old school classic

Project description

pyautoeios

Work in progress port remote_input from https://github.com/Brandon-T/Reflection to python

Design decision was made to implements patches to https://github.com/asweigart/pyautogui/ and github.com/asweigart/pyscreeze so that the remote_input so that interface can be used.

Planned Features

  • Works with python 3.8
  • installable via pip
  • Wraps well liked pyautogui interface
  • Transparent Image finding when opencv is installed
  • Injecting into multiple clients (so threads can be used for multi-boxing)
  • no known memory leaks.

Backlog Features:

Current demo:

import random
import getpass
from pyscreeze import Box
import pyautoeios as pyauto


def move_to_spot_in_box(box, **kwargs):
    print(f"box = {box}")
    if 'duration' not in kwargs:
        kwargs['duration'] = random.uniform(0.3,1.1)
    if 'tween' not in kwargs:
        kwargs['tween'] = pyauto.easeOutQuad

    cx,cy =  pyauto.center(box)
    x = random.randint(int(-1*(box.width/3)),int(box.width/3)) + cx
    y = random.randint(int(-1*(box.height/3)),int(box.height/3)) + cy 
    print(f"x = {x}, y = {y}")
    pyauto.moveTo(x, y, **kwargs)


def click_on_spot_in_box(box, **kwargs):
    move_to_spot_in_box(box,**kwargs)
    pyauto.click(**kwargs)

pyauto.inject_clients()
for client in pyauto.clients:
    pyauto.pair_client(client)
    click_on_spot_in_box(Box(left=398, top=271, width=148, height=40))
    click_on_spot_in_box(Box(left=285, top=248, width=235, height=15))
    pyauto.typewrite(getpass.getpass(), interval=0.3)
    im = pyauto.screenshot()
    im.show()
    click_on_spot_in_box(Box(left=238, top=301, width=148,height=41))

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyautoeios-0.0.2.tar.gz (1.1 MB view hashes)

Uploaded Source

Built Distribution

pyautoeios-0.0.2-py3-none-any.whl (18.6 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page