randsleep autoclicker bot

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
densch

randsleep autoclicker bot

23 May 2018, 10:08

Hello,
by searching the internet and stuff, I scrambled the beneath code together.
What it should do:
in a specific window it should click on a specific point repeatedly, with a random time between each 2 clicks.
the whole thing should even work if that window is in the background and I'm dog completely other stuff in the foreground.

Now do you think that the code is okay so far, so that it does just that?

time should be chosen to be between 35 and 120 seconds, is that done right?

and 2 things that I was not able to find out about:
For the skript to be "bound" to that specific window, I need to know that windws class name.
How can I find that out?

Google brought me only to other forums with some crazy code to execute, ain't there some easy way, like finding that class name via task manager or stuff (I'm using windows 10)?

to be precisely, I wanna use that script on a certain telegram channel. or rather the telegram window itself.

how can I easy and noob-friendly find the class name of the window?

and another thing:
How's the orientation of the coordinate system? is x horicontal and y vertical distance?
where's the origin?
What's the smartest way to get the coordinates of the point that I want it to click?


Sorry for all the noob questions but I only know AHK and it's programming language for like 1 hour, so I have no idea.
And yeah, I never had C++ in school.
Only python, java and stuff.


















Code: Select all

#SingleInstance, Force
#NoEnv
SendMode Input
fire := 0

NumpadDiv::SetTimer, AutoFire, % (fire := !fire) ? RandSleep() : "Off"

AutoFire:
ControlClick, x850 y400, ahk_class ApolloRuntimeContentWindow,,,, Pos
 return
 
 RandSleep() {
Random, rand, 35000, 120000
Sleep %rand%
}
please place your code in [code][/code] tags!

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: Anput, DiegoSouto, Google [Bot], mikeyww, Rohwedder, Sniperman, Swiftly9767 and 382 guests