n00b-asaurus / Redstone-Development-Kit

A collection of tools used to develop, test, and troubleshoot redstone circuits.
MIT License
11 stars 1 forks source link

pydirectinput only works on Windows #19

Open bobvicktor opened 3 years ago

bobvicktor commented 3 years ago

So far the only issue I have seen using the RDK on macOS is with pydirectinput, but it prevents me from even running the the Redstone Structure Generator without modification, so there may be others I haven't seen yet.

I'm willing to look in to this myself, but I won't be able to try it out on Windows until next week some time, so if you get a chance to look in to it first let me know and I can test on macOS.

Importing pydirectinput in AutoTyper gives the following error:

AttributeError: module 'ctypes' has no attribute 'windll'

Full error:

Traceback (most recent call last): File "/Users/user/Developer/Redstone-Development-Kit/Redstone Structure Generator Tool/Redstone Structure Generator.py", line 7, in from string_handlers.autotyper import AutoTyper File "/Users/user/Developer/Redstone-Development-Kit/Redstone Structure Generator Tool/string_handlers/autotyper.py", line 1, in from pydirectinput import press, keyDown, keyUp File "/Users/user/Library/Python/3.9/lib/python/site-packages/pydirectinput/init.py", line 6, in SendInput = ctypes.windll.user32.SendInput AttributeError: module 'ctypes' has no attribute 'windll'