AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

random click

 
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
guest84
Guest





PostPosted: Sun Nov 22, 2009 3:11 am    Post subject: random click Reply with quote

anybody know a way to randomize a mouse click. after i put in sleep i want to randomize a number between like 2000-50000 so the clicks r not all the same time. any help would be very appreciated thank you.
Back to top
i3egohan



Joined: 18 Jul 2006
Posts: 403

PostPosted: Sun Nov 22, 2009 3:21 am    Post subject: Reply with quote

Random click every 5 seconds.

Code:
Loop
{
    Random, randx, 0, %A_ScreenWidth%
    Random, randy, 0, %A_ScreenHeight%
    Click, %randx%, %randy%
    Sleep, 5000 ; random click every 5 seconds
}

F2::ExitApp


Hit F2 to exit.
Back to top
View user's profile Send private message
guest84
Guest





PostPosted: Sun Nov 22, 2009 3:25 am    Post subject: Reply with quote

But I need it not to always be the same interval between clicks.
Back to top
entropic



Joined: 21 Dec 2008
Posts: 181

PostPosted: Sun Nov 22, 2009 3:38 am    Post subject: Reply with quote

He basically showed you how to do it...

Code:

Loop
{
    Random, randx, 0, %A_ScreenWidth%
    Random, randy, 0, %A_ScreenHeight%
    ; Generate a random number between 2,000 - 5,000
    Random, sleeptime, 2000, 5000
    Click, %randx%, %randy%
    ; Sleep for 2-5 seconds
    Sleep, %sleeptime%
}

F2::ExitApp
Back to top
View user's profile Send private message
guest84
Guest





PostPosted: Sun Nov 22, 2009 4:12 am    Post subject: Reply with quote

this is what i am using. please help make it random. I am hoping to get the clicks random between 25 seconds and 120 seconds.

loop{

mouseclick, right, 957, 449 ;

sleep 3500

send {ESC} ;

sleep 1500 ;
}
^!p::Pause
Back to top
sinkfaze



Joined: 18 Mar 2008
Posts: 5044
Location: the tunnel(?=light)

PostPosted: Sun Nov 22, 2009 4:48 am    Post subject: Reply with quote

guest84 wrote:
this is what i am using. please help make it random.


They did help you make it random, please try what they suggested. If it doesn't work then post your code so they can look at it and try to help you further.
_________________
Try Quick Search for Autohotkey or see the tutorial for newbies.
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group