firefox click - background

Get help with using AutoHotkey and its commands and hotkeys
Makaronik
Posts: 4
Joined: Yesterday, 11:52

firefox click - background

Yesterday, 12:02

Hello, I tried to create background script in ahk but it doesn't work ;v any suggest why it's not working?
I will be grateful if you help me :)

Code: Select all

ControlClick, x642 y142, Firefox
	sleep, 5000
ControlClick, x424 y169, Firefox
	sleep, 35000
ControlClick, x956 y207, Firefox
	sleep, 1500
ControlClick, x164 y711, Firefox
	sleep, 1500
ControlClick, x1272 y90, Firefox
	sleep, 1000
ControlClick, x1271 y90, Firefox
	sleep, 1500
ControlClick, x334 y20, Firefox
	sleep, 1000
ControlClick, x824 y362, Firefox
	sleep, 1000
ControlClick, x828 y582, Firefox
	sleep, 1000
ControlClick, x828 y582, Firefox
	sleep, 1000
ControlClick, x597 y441, Firefox
	sleep, 1000
ControlClick, x597 y441, Firefox
	sleep, 1000
ControlClick, x157 y18, Firefox
	sleep, 1000
ControlClick, x88 y50, Firefox
	sleep, 9000
ControlClick, x90 y55, Firefox
	sleep, 17000
ControlClick, x862 y757, Firefox
	sleep, 1500
ControlClick, x791 y588, Firefox
	sleep, 1000
ControlClick, x797 y286, Firefox
	sleep 1200
Send {o}, Firefox
	sleep, 100
Send {p}, Firefox
	sleep, 100
Send {o}, Firefox
	sleep, 100
Send {p}, Firefox
	sleep, 100
Send {o}, Firefox
	sleep, 100
Send {i}, Firefox
	sleep, 7000
Send {tab}, Firefox
	sleep, 1000
Send {1}, Firefox
	sleep, 100
Send {1}, Firefox
	sleep, 100
Send {1}, Firefox
	sleep, 100
Send {1}, Firefox
	sleep, 100
Send {2}, Firefox
	sleep, 100
Send {1}, Firefox
	sleep, 100
Send {2}, Firefox
	sleep, 100
Send {3}, Firefox
	sleep, 3000
ControlClick, x925 y687, Firefox
	sleep, 5000
ControlClick, x372 y465, Firefox
	sleep, 2000
ControlClick, x839 y469, Firefox
	sleep, 1000
ControlClick, x194 y246, Firefox
	sleep, 30000
User avatar
Scr1pter
Posts: 928
Joined: 06 Aug 2017, 08:21
Location: Germany

Re: firefox click - background

Yesterday, 12:28

Hi,
1. Replace Firefox by ahk_class MozillaWindowClass
2. Check if the coordinates are really correct
3. Replace Send by ControlSend

Example:

Code: Select all

ControlClick, x797 y286, ahk_class MozillaWindowClass
Sleep, 1200
ControlSend, {o}, ahk_class MozillaWindowClass
Also, you don't need so many lines.
You can send the keys with 1 ControlSend.

Cheers!
I ignore every thread which contains the P-word :x
(Hint: It rhymes on Shython)
Please do not support cheaters!
Keyboard: Logitech G15 FE - Mice: Logitech G9 FE, G502 FE, G602 - OS: Windows 10 Pro 64 Bit - AHK version: 1.1.29.00
Makaronik
Posts: 4
Joined: Yesterday, 11:52

Re: firefox click - background

Yesterday, 13:03

Scr1pter wrote:
Yesterday, 12:28
Hi,
1. Replace Firefox by ahk_class MozillaWindowClass
2. Check if the coordinates are really correct
3. Replace Send by ControlSend

Example:

Code: Select all

ControlClick, x797 y286, ahk_class MozillaWindowClass
Sleep, 1200
ControlSend, {o}, ahk_class MozillaWindowClass
Also, you don't need so many lines.
You can send the keys with 1 ControlSend.

Cheers!
Thanks but coordinates are correct and still not clicking on site. Script work when i want to change a card in a firefox but still not clicking on the site. If i want click submit when i reply post, script doesnt click and i have to do it manually. ;-;
Makaronik
Posts: 4
Joined: Yesterday, 11:52

Re: firefox click - background

Yesterday, 13:15

Thanks, but coordinates are correct and script still not clicking on site. Script work when I want to change a card in a firefox but still not clicking on the site. If I want click submit when I reply post, script doesnt click. ;x
User avatar
Scr1pter
Posts: 928
Joined: 06 Aug 2017, 08:21
Location: Germany

Re: firefox click - background

Yesterday, 13:28

Can you explain what exactly you're trying to do?
Also, why those extremely long sleeping times?
Do you want to let the script wait until a site has been loaded?

Cheers!
I ignore every thread which contains the P-word :x
(Hint: It rhymes on Shython)
Please do not support cheaters!
Keyboard: Logitech G15 FE - Mice: Logitech G9 FE, G502 FE, G602 - OS: Windows 10 Pro 64 Bit - AHK version: 1.1.29.00
Makaronik
Posts: 4
Joined: Yesterday, 11:52

Re: firefox click - background

Yesterday, 14:03

I need script to use like bot in game :p
bot have to load site, refresh, login and click in game but hes not clicking
ControlClick, x642 y142, ahk_class MozillaWindowClass - will not click menu in browser game but when want to change cards in firefox he will do it. So... I dont understand why :D

Code: Select all

ControlClick, x642 y142, ahk_class MozillaWindowClass
sleep, 5000
ControlClick, x434 y171, ahk_class MozillaWindowClass
sleep, 35000
ControlClick, x956 y213, ahk_class MozillaWindowClass
sleep, 1500
ControlClick, x128 y706, ahk_class MozillaWindowClass
sleep, 1500
ControlClick, x1272 y90, ahk_class MozillaWindowClass
sleep, 1000
ControlClick, x1271 y90, ahk_class MozillaWindowClass
sleep, 1500
ControlClick, x334 y20, ahk_class MozillaWindowClass
sleep, 1000
ControlClick, x824 y362, ahk_class MozillaWindowClass
sleep, 1000
ControlClick, x828 y582, ahk_class MozillaWindowClass
sleep, 1000
ControlClick, x828 y582, ahk_class MozillaWindowClass
sleep, 1000
ControlClick, x597 y441, ahk_class MozillaWindowClass
sleep, 1000
ControlClick, x597 y441, ahk_class MozillaWindowClass
sleep, 1000
ControlClick, x157 y18, ahk_class MozillaWindowClass
sleep, 1000
ControlClick, x88 y50, ahk_class MozillaWindowClass
sleep, 9000
ControlClick, x90 y55, ahk_class MozillaWindowClass
sleep, 17000
ControlClick, x862 y757, ahk_class MozillaWindowClass
sleep, 1500
ControlClick, x791 y588, ahk_class MozillaWindowClass
sleep, 1000
ControlClick, x797 y286, ahk_class MozillaWindowClass
sleep 1200
Send {l}, ahk_class MozillaWindowClass
sleep, 100
Send {o}, ahk_class MozillaWindowClass
sleep, 100
Send {g}, ahk_class MozillaWindowClass
sleep, 100
Send {i}, ahk_class MozillaWindowClass
sleep, 100
Send {n}, ahk_class MozillaWindowClass
sleep, 100
Send {1}, ahk_class MozillaWindowClass
sleep, 7000
Send {tab}, ahk_class MozillaWindowClass
sleep, 1000
Send {p}, ahk_class MozillaWindowClass
sleep, 100
Send {a}, ahk_class MozillaWindowClass
sleep, 100
Send {s}, ahk_class MozillaWindowClass
sleep, 100
Send {s}, ahk_class MozillaWindowClass
sleep, 100
Send {w}, ahk_class MozillaWindowClass
sleep, 100
Send {o}, ahk_class MozillaWindowClass
sleep, 100
Send {r}, ahk_class MozillaWindowClass
sleep, 100
Send {d}, ahk_class MozillaWindowClass
sleep, 3000
ControlClick, x925 y687, ahk_class MozillaWindowClass
sleep, 5000
ControlClick, x372 y465, ahk_class MozillaWindowClass
sleep, 2000
ControlClick, x839 y469, ahk_class MozillaWindowClass
sleep, 1000
ControlClick, x194 y246, ahk_class MozillaWindowClass
sleep, 30000

Return to “Ask For Help”

Who is online

Users browsing this forum: alonzam99, Azuc, Bing [Bot], Google [Bot], Makaronik, paik1002, Scr1pter, sinkfaze, teadrinker and 38 guests