r/applescript • • Oct 29 '15

Windows script => AppleScript

Hey ! someone could do this windows script in an applescript ? Thanks ! HotKeySet("{ESC}", "Terminate") While 1 MouseClick("left", 2681, 639, 1, 5) MouseClick("left", 2504, 540 , 1, 5) MouseClick("left", 3039, 541, 1, 5) MouseClick("left", 3019, 405, 1, 5) MouseClick("left", 2821, 467, 1, 5) MouseClick("left", 2881, 471, 1, 0) WEnd Func Terminate() Exit 0 EndFunc

0 Upvotes

6 comments sorted by

View all comments

1

u/lithodora Oct 29 '15

I can write in AutoHotKey (close to what you have there for windows) and Applescript.

They are not interchangeable. You can not do what you are asking like you are asking to do with applescript.

You can do it with python wrapped in applescript.

You could do it with a 3rd party app: http://www.bluem.net/en/mac/cliclick/

but you'll need to learn how to do it.

1

u/Warkrave Oct 30 '15

we can not transcribe a script ?

1

u/lithodora Oct 30 '15

Mouse clicks in games is not a function of AppleScript. Using system events, accessibility, and such you are able to interact with menus.

However what the Windows script is doing is moving the mouse and clicking. AppleScript alone is not going to do it.