Sign in to follow this  
Followers 0
stefan654

Adding instructions to my script

8 posts in this topic

#1 ·  Posted (edited)

hello guys i made this code atm to store mousepositions (and that i can easily acces them with iniread):

hotKeySet("a","getpos1")
hotKeySet("z","getpos2")
hotKeySet("e","getpos3")
hotKeySet("r","getpos4")
hotKeySet("t","getpos5")
hotKeySet("y","getpos6")
hotKeySet("u","getpos7")
hotKeySet("i","getpos8")
hotKeySet("o","getpos9")
hotKeySet("p","getpos10")
hotKeySet("q","getpos11")
hotKeySet("s","getpos12")
hotKeySet("d","getpos13")
hotKeySet("f","getpos14")
 
;banker
$SettingsFile1 = @SCRIPTDIR & '\Settings1.ini'
$SettingsFile2 = @SCRIPTDIR & '\Settings2.ini'
$SettingsFile3 = @SCRIPTDIR & '\Settings3.ini'
$SettingsFile4 = @SCRIPTDIR & '\Settings4.ini'
$SettingsFile5 = @SCRIPTDIR & '\Settings5.ini'
$SettingsFile6 = @SCRIPTDIR & '\Settings6.ini'
$SettingsFile7 = @SCRIPTDIR & '\Settings7.ini'
$SettingsFile8 = @SCRIPTDIR & '\Settings8.ini'
$SettingsFile9 = @SCRIPTDIR & '\Settings9.ini'
$SettingsFile10 = @SCRIPTDIR & '\Settings10.ini'
$SettingsFile11 = @SCRIPTDIR & '\Settings11.ini'
$SettingsFile12 = @SCRIPTDIR & '\Settings12.ini'
$SettingsFile13 = @SCRIPTDIR & '\Settings13.ini'
$SettingsFile14 = @SCRIPTDIR & '\Settings14.ini'
$SettingsFile15 = @SCRIPTDIR & '\Settings15.ini'
$SettingsFile16 = @SCRIPTDIR & '\Settings16.ini'
$SettingsFile17 = @SCRIPTDIR & '\Settings17.ini'
$SettingsFile18 = @SCRIPTDIR & '\Settings18.ini'
$SettingsFile19 = @SCRIPTDIR & '\Settings19.ini'
$SettingsFile20 = @SCRIPTDIR & '\Settings20.ini'
$SettingsFile21 = @SCRIPTDIR & '\Settings21.ini'
$SettingsFile22 = @SCRIPTDIR & '\Settings22.ini'
$SettingsFile23 = @SCRIPTDIR & '\Settings23.ini'
$SettingsFile24 = @SCRIPTDIR & '\Settings24.ini'
$SettingsFile25 = @SCRIPTDIR & '\Settings25.ini'
$SettingsFile26 = @SCRIPTDIR & '\Settings26.ini'
$SettingsFile27 = @SCRIPTDIR & '\Settings27.ini'
$SettingsFile28 = @SCRIPTDIR & '\Settings28.ini'
 
 
 
 
while 1    
sleep (100)
WEnd
 
 
 
 
 
 
Func getpos1()
Local $pos = MouseGetPos()
iniWrite ( $SettingsFile1, 'Poss', 'ypos', $pos[1] )
iniWrite ( $SettingsFile2, 'Poss', 'ypos', $pos[0] )
EndFunc
While 2
sleep (100)
WEnd
 
Func getpos2()
Local $pos = MouseGetPos()
iniWrite ( $SettingsFile3, 'Poss', 'ypos', $pos[1] )
iniWrite ( $SettingsFile4, 'Poss', 'ypos', $pos[0] )
EndFunc
While 2
sleep (100)
WEnd
 
Func getpos3()
Local $pos = MouseGetPos()
iniWrite ( $SettingsFile5, 'Poss', 'ypos', $pos[1] )
iniWrite ( $SettingsFile6, 'Poss', 'ypos', $pos[0] )
EndFunc
While 2
sleep (100)
WEnd
 
Func getpos4()
Local $pos = MouseGetPos()
iniWrite ( $SettingsFile7, 'Poss', 'ypos', $pos[1] )
iniWrite ( $SettingsFile8, 'Poss', 'ypos', $pos[0] )
EndFunc
While 2
sleep (100)
WEnd
 
Func getpos5()
Local $pos = MouseGetPos()
iniWrite ( $SettingsFile9, 'Poss', 'ypos', $pos[1] )
iniWrite ( $SettingsFile10, 'Poss', 'ypos', $pos[0] )
EndFunc
While 2
sleep (100)
WEnd
 
Func getpos6()
Local $pos = MouseGetPos()
iniWrite ( $SettingsFile11, 'Poss', 'ypos', $pos[1] )
iniWrite ( $SettingsFile12, 'Poss', 'ypos', $pos[0] )
EndFunc
While 2
sleep (100)
WEnd
 
Func getpos7()
Local $pos = MouseGetPos()
iniWrite ( $SettingsFile13, 'Poss', 'ypos', $pos[1] )
iniWrite ( $SettingsFile14, 'Poss', 'ypos', $pos[0] )
EndFunc
While 2
sleep (100)
WEnd
 
Func getpos8()
Local $pos = MouseGetPos()
iniWrite ( $SettingsFile15, 'Poss', 'ypos', $pos[1] )
iniWrite ( $SettingsFile16, 'Poss', 'ypos', $pos[0] )
EndFunc
While 2
sleep (100)
WEnd
 
Func getpos9()
Local $pos = MouseGetPos()
iniWrite ( $SettingsFile17, 'Poss', 'ypos', $pos[1] )
iniWrite ( $SettingsFile18, 'Poss', 'ypos', $pos[0] )
EndFunc
While 2
sleep (100)
WEnd
 
Func getpos10()
Local $pos = MouseGetPos()
iniWrite ( $SettingsFile19, 'Poss', 'ypos', $pos[1] )
iniWrite ( $SettingsFile20, 'Poss', 'ypos', $pos[0] )
EndFunc
While 2
sleep (100)
WEnd
 
Func getpos11()
Local $pos = MouseGetPos()
iniWrite ( $SettingsFile21, 'Poss', 'ypos', $pos[1] )
iniWrite ( $SettingsFile22, 'Poss', 'ypos', $pos[0] )
EndFunc
While 2
sleep (100)
WEnd
 
Func getpos12()
Local $pos = MouseGetPos()
iniWrite ( $SettingsFile23, 'Poss', 'ypos', $pos[1] )
iniWrite ( $SettingsFile24, 'Poss', 'ypos', $pos[0] )
EndFunc
While 2
sleep (100)
WEnd
 
Func getpos13()
Local $pos = MouseGetPos()
iniWrite ( $SettingsFile25, 'Poss', 'ypos', $pos[1] )
iniWrite ( $SettingsFile26, 'Poss', 'ypos', $pos[0] )
EndFunc
While 2
sleep (100)
WEnd
 
Func getpos14()
Local $pos = MouseGetPos()
iniWrite ( $SettingsFile27, 'Poss', 'ypos', $pos[1] )
iniWrite ( $SettingsFile28, 'Poss', 'ypos', $pos[0] )
EndFunc
While 2
sleep (100)
WEnd
Edited by stefan654

Share this post


Link to post
Share on other sites



What i actually want to achieve:

the script giving me instructions via tooltips, for example: "press z now", "press e now",....

If i just add tooltips to the functions it will appear after i pressed the button, that's not the point.

I want it to go chronologically :/

kind regards!

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

No i attempted to modify a general mousepositioning tool (as i found many of those on the forums)

So that i do not always have to write down the coordinates from the tool, but can just use iniread functions to automatically load up the coords in another file.

Kind regards

Edited by stefan654

Share this post


Link to post
Share on other sites

#5 ·  Posted (edited)

What application does this tool interact with? That is what I'm looking for here. I say this for three reasons -

1. The hotkeys listed are just about all for the left hand - as if your playing a game.

2. you have listed ":banker" in your script. (makes me think it is a game reference)

3. kal private server (from the few other post) is mainly used for games.

So, I ask again. Is this mouse tool to be used for a game? It is a straight up yes or no here.

Edited by MBALZESHARI

Share this post


Link to post
Share on other sites

#6 ·  Posted (edited)

no.

First of all i dont see why gamers would only need a left mouseclick, furthermore: where do u see i only use left mouse clicks? This script is to get the coordinates of the mouse right? i mean it never has to click anywhere :o?

And i've used banker because it's a dutch word for a profession.

Furthermore: i've asked questions about kalonline in the past, which was the reason why i started looking into autoit indeed. But i think many people actually start out at that point: you want to learn to improve your current situation. I moved passed that point now, and am actually using autoit to enhance the ease of fulfilling daily tasks / to do fancy stuff with it...like adding a freakin tooltip.

I dont see ANY reason why a tooltip could BENEFIT you AT ALL in a game...

I understand your suspiscion, yet it's kinda....euhm...annoying

And like i said in the post above, it does not interact with anything. It's a standalone script to get mouse positions... god -.-

Anyway someone else has helped me out by now.

Thanks for attempting though!

Edited by stefan654

Share this post


Link to post
Share on other sites

no.

First of all i dont see why gamers would only need a left mouseclick, furthermore: where do u see i only use left mouse clicks? This script is to get the coordinates of the mouse right? i mean it never has to click anywhere :o?

And i've used banker because it's a dutch word for a profession.

Furthermore: i've asked questions about kalonline in the past, which was the reason why i started looking into autoit indeed. But i think many people actually start out at that point: you want to learn to improve your current situation. I moved passed that point now, and am actually using autoit to enhance the ease of fulfilling daily tasks / to do fancy stuff with it...like adding a freakin tooltip.

I dont see ANY reason why a tooltip could BENEFIT you AT ALL in a game...

I understand your suspiscion, yet it's kinda....euhm...annoying

And like i said in the post above, it does not interact with anything. It's a standalone script to get mouse positions... god -.-

Anyway someone else has helped me out by now.

Thanks for attempting though!

Thank you for your response. Have a nice day.

Share this post


Link to post
Share on other sites

Try this.

Global $HK[14] = ["a", "z", "e", "r", "t", "y", "u", "i", "o", "p", "q", "s", "d", "f"]

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

For $i = 0 To UBound($HK) - 1
    HotKeySet($HK[$i], "getpos")
Next
ToolTip('Press "' & $HK[0] & @LF & '"' & 'or' & @LF & 'Press "Esc" to exit.', 0, 0)

While 1
    Sleep(100)
WEnd


Func getpos()
    Static $iNum = 0
    If @HotKeyPressed == $HK[$iNum] Then
        MsgBox(0, "HotKey", '@HotKeyPressed = "' & @HotKeyPressed & '"' & @LF & '  Position: ' & MouseGetPos(0) & "  " & MouseGetPos(1), 2)
        $iNum = Mod($iNum + 1, UBound($HK))
        ToolTip('Press "' & $HK[$iNum] & @LF & '"' & 'or' & @LF & 'Press "Esc" to exit.', 0, 0)
    EndIf
EndFunc   ;==>getpos

Func Terminate()
    Exit
EndFunc   ;==>Terminate

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