Jump to content
Sign in to follow this  
Hawker

need help with simple script :D

Recommended Posts

Hawker

could anyone tell me how to make a script that does double right click every 1 second with a key for on/off? <_<

Share this post


Link to post
Share on other sites
Generator

By that, Look in

HotKeySet()

MouseClick()

Sleep()

While/WEnd Loop

Share this post


Link to post
Share on other sites
CyNDeR

Sure. Download the latest Autoit, open the help file and lookup, HotKeySet(), Sleep(), MouseClick(), and While/WEnd loop.

EDIT: oops, beat me to it.

Edited by CyNDeR

My scripts: Random Painter

Share this post


Link to post
Share on other sites
Hawker

um could uguys write one up fast for me? lol first time using autoit

Share this post


Link to post
Share on other sites
Generator

um could uguys write one up fast for me? lol first time using autoit

Edit: Try it and post here for help. Edited by Generator

Share this post


Link to post
Share on other sites
Hawker

it's harder than i thought. harder then actools for sure <_<

Edited by Hawker

Share this post


Link to post
Share on other sites
Hawker

um...help plz <_<

; Press Home to terminate script, ] to "pause"

Global $Paused

HotKeySet("{]}", "TogglePause")

HotKeySet("{Home}", "Terminate")

HotKeySet("{F12}", "ShowMessage") ;Shift-Alt-d

;;;; Body of program would go here ;;;;

While 1

Sleep(100)

WEnd

;;;;;;;;

Func TogglePause(])

$Paused = NOT $Paused

While $Paused

sleep(100)

ToolTip('Script is "Paused"',0,0)

WEnd

ToolTip("")

EndFunc

Func Terminate(home)

Exit 0

EndFunc

Func ShowMessage(F12)

MsgBox(4096,"","This is a message.")

EndFunc

; Double click at the current mouse pos

MouseClick("right")

MouseClick("right")

Sleep(1000) ;one second

$i = 0

While $i <= 10

MsgBox(0, "Value of $i is:", $i)

$i = $i + 1

WEnd

Edited by Hawker

Share this post


Link to post
Share on other sites
Generator

Global $Paused=0
HotKeySet("{]}", "TogglePause")
HotKeySet("{Home}", "Terminate")
HotKeySet("{F12}", "ShowMessage") ;Shift-Alt-d
HotKeySet("{F11}", "_Click")

;;;; Body of program would go here ;;;;
While 1
Sleep(1)
WEnd
;;;;;;;;

Func TogglePause()
$Paused = NOT $Paused
EndFunc

Func Terminate()
Exit 0
EndFunc

Func ShowMessage()
MsgBox(4096,"","This is a message.")

EndFunc
; Double click at the current mouse pos


Func _Click()
    While Not $Paused
    MouseClick("right")
    MouseClick("right")
    Sleep(1000) ;five seconds
    WEnd
EndFunc

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.