Sign in to follow this  
Followers 0
proitems1

mouse clicks

3 posts in this topic

ok im trying to make the mouse click like all the time and i keep having problems maybe some one can help me out heres my code

Opt("WinWaitDelay",100)

Opt("WinTitleMatchMode",4)

Opt("WinDetectHiddenText",1)

Opt("MouseCoordMode",0)

WinWait("SwgClient","")

If Not WinActive("SwgClient","") Then WinActivate("SwgClient","")

WinWaitActive("SwgClient","")

While 1

MouseMove(219,212)

MouseClick("Left", 219, 212)

thx in advance for the help im a noob

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

We can't see your code unless you use Code Tags [ Code] at the beginning and [ /Code] at the end ... both without spaces.

HotKeySet('{Esc}', '_PanicExit');Press Esc if you want to exit the script.
Opt("WinWaitDelay",100)
Opt("WinTitleMatchMode",4)
Opt("MouseCoordMode",0)
WinWait("SwgClient");is SwgClient the Class?
While WinExists('SwgClient')
    If Not WinActive("SwgClient") Then WinActivate("SwgClient")
    WinWaitActive("SwgClient")
    MouseClick("Left", 219, 212, 1, 1)
    Sleep(10)
WEnd

Func _PanicExit()
    Exit
EndFunc
Edited by SmOke_N

[center]Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.[/center]

Share this post


Link to post
Share on other sites

HI,

try this:

HotKeySet("1", "end")
Opt("WinWaitDelay",100)
Opt("WinTitleMatchMode",4)
Opt("WinDetectHiddenText",1)
Opt("MouseCoordMode",0)

$title = "SwgClient"

WinWait($title,"")
While 1
If Not WinActive($title,"") Then WinActivate($title,"")
MouseClick("Left", 219, 212, 1, 1)
WEnd

Func end()
    Exit (0)    
EndFunc   ;==>end

So long,

Mega


Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

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  
Followers 0