Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #MaxThreadsPerHotkey 4
- F4::
- Toggle := !Toggle
- If Toggle {
- MsgBox, "ON"
- Click, Down
- } else {
- MsgBox, "OFF"
- Click, Up
- }
- loop
- {
- If not Toggle
- break
- RandomMouseMove()
- RandSleep(10000,20000) ;sleep a random length of time
- }
- RandSleep(x,y) {
- Random, rand, %x%, %y%
- Sleep %rand%
- }
- RandomMouseMove(){
- MouseGetPos, xpos, ypos
- x := Rand(0, A_ScreenWidth / 1.1)
- y := Rand(0, A_ScreenHeight)
- time := "T" + Rand(5000,6000)
- OT := " OT" + Rand(62,173)
- OB := " OB" + Rand(62,173)
- OL := " OL" + Rand(62,173)
- OR := " OR" + Rand(62,173)
- P := " P19"
- option = %time%%OT%%OB%%OL%%OR%%P%
- RandomBezier(xpos, ypos, x, y, option)
- Return
- }
- RandomBezier( X0, Y0, Xf, Yf, O="" ) {
- Time := RegExMatch(O,"i)T(\d+)",M)&&(M1>0)? M1: 200
- RO := InStr(O,"RO",0) , RD := InStr(O,"RD",0)
- N:=!RegExMatch(O,"i)P(\d+)(-(\d+))?",M)||(M1<2)? 2: (M1>19)? 19: M1
- If ((M:=(M3!="")? ((M3<2)? 2: ((M3>19)? 19: M3)): ((M1=="")? 5: ""))!="")
- Random, N, %N%, %M%
- OfT:=RegExMatch(O,"i)OT(-?\d+)",M)? M1: 100, OfB:=RegExMatch(O,"i)OB(-?\d+)",M)? M1: 100
- OfL:=RegExMatch(O,"i)OL(-?\d+)",M)? M1: 100, OfR:=RegExMatch(O,"i)OR(-?\d+)",M)? M1: 100
- MouseGetPos, XM, YM
- If ( RO )
- X0 += XM, Y0 += YM
- If ( RD )
- Xf += XM, Yf += YM
- If ( X0 < Xf )
- sX := X0-OfL, bX := Xf+OfR
- Else
- sX := Xf-OfL, bX := X0+OfR
- If ( Y0 < Yf )
- sY := Y0-OfT, bY := Yf+OfB
- Else
- sY := Yf-OfT, bY := Y0+OfB
- Loop, % (--N)-1 {
- Random, X%A_Index%, %sX%, %bX%
- Random, Y%A_Index%, %sY%, %bY%
- }
- X%N% := Xf, Y%N% := Yf, E := ( I := A_TickCount ) + Time
- While ( A_TickCount < E ) {
- U := 1 - (T := (A_TickCount-I)/Time)
- Loop, % N + 1 + (X := Y := 0) {
- Loop, % Idx := A_Index - (F1 := F2 := F3 := 1)
- F2 *= A_Index, F1 *= A_Index
- Loop, % D := N-Idx
- F3 *= A_Index, F1 *= A_Index+Idx
- M:=(F1/(F2*F3))*((T+0.000001)**Idx)*((U-0.000001)**D), X+=M*X%Idx%, Y+=M*Y%Idx%
- }
- MouseMove, %X%, %Y%, 0
- Sleep, 1
- }
- MouseMove, X%N%, Y%N%, 0
- Return N+1
- }
- Rand(min, max){
- Random, rand, % min, % max
- Return rand
- }
Advertisement
Add Comment
Please, Sign In to add comment