AutoLogin v0.38
Ok, today was the last school day before holidays...
well so i got some time to do a tutorial, how to build a better AutoLogin tool!
Things u need:
AutoIt
AutoIt Window Info Tool (should be in the AutoIt installation)
Scite - u can do it with an normal editor, too, but scite owns =P
Brain v.1337
logical understandment (woot, english sucks -.-)
Some experiences in coding with AutoIt are usefull
First ill post the Tool, after that u will find the Source + Tutorial
So heres the Tool:
AutoLogin by HideAndSeek v0.38
Special Thanks to lolkop - i think hes active here, too =P
What is the tool able to do:
- Start silkroad
- filling in ID & PW
- Enter Spam
- knows when ure looged in
- Beep, if logged in
- Character select & log in
- Hide Silkroad
- Show Silkroad
- Exit Silkroad
Einstellungen:
- fill in your ID & PW into the 2 Input boxes
- Choose the path of your Silkroad Launcher (normally silkroad.exe)
- Time that is needed to start Silkroad
- The Reconnect time
[img]http://image.**********/pics/4a54970d14027.jpg[/img]
Pls post bugs/suggestions to make the tool even better
VirusTotal:Quote:
AutoLogin v0.38
- Fixed Download-link
- Server Change is now in the "new" Version
AutoLogin v0.37
-DLL Calls removed, due to some mistakes -.-
arent there Spoilers here ? -.-Quote:
a-squared 4.0.0.101 2009.06.04 -
a-squared 4.5.0.18 2009.06.27 -
AhnLab-V3 5.0.0.2 2009.06.27 -
AntiVir 7.9.0.199 2009.06.26 -
Antiy-AVL 2.0.3.1 2009.06.26 Trojan/Win32.AutoIt.gen
Authentium 5.1.2.4 2009.06.27 -
Avast 4.8.1335.0 2009.06.26 -
AVG 8.5.0.339 2009.06.27 -
BitDefender 7.2 2009.06.27 -
CAT-QuickHeal 10.00 2009.06.26 -
ClamAV 0.94.1 2009.06.27 -
Comodo 1457 2009.06.27 -
DrWeb 5.0.0.12182 2009.06.27 -
eSafe 7.0.17.0 2009.06.25 Suspicious File
eTrust-Vet 31.6.6582 2009.06.26 -
F-Prot 4.4.4.56 2009.06.27 -
F-Secure 8.0.14470.0 2009.06.27 -
Fortinet 3.117.0.0 2009.06.27 -
GData 19 2009.06.27 -
Ikarus T3.1.1.64.0 2009.06.27 -
Jiangmin 11.0.706 2009.06.27 -
K7AntiVirus 7.10.768 2009.06.19 -
Kaspersky 7.0.0.125 2009.06.27 -
McAfee 5659 2009.06.27 -
McAfee+Artemis 5659 2009.06.27 -
McAfee-GW-Edition 6.7.6 2009.06.27 -
Microsoft 1.4803 2009.06.27 -
NOD32 4193 2009.06.26 -
Norman 6.01.09 2009.06.26 -
nProtect 2009.1.8.0 2009.06.27 -
Panda 10.0.0.16 2009.06.27 -
PCTools 4.4.2.0 2009.06.26 -
Prevx 3.0 2009.06.27 -
Rising 21.35.52.00 2009.06.27 -
Sophos 4.43.0 2009.06.27 -
Sunbelt 3.2.1858.2 2009.06.27 -
Symantec 1.4.4.12 2009.06.27 -
TheHacker 6.3.4.3.356 2009.06.27 -
TrendMicro 8.950.0.1094 2009.06.26 -
VBA32 3.12.10.7 2009.06.27 -
ViRobot 2009.6.27.1808 2009.06.27 -
VirusBuster 4.6.5.0 2009.06.27 -
Well, the program isnt the best, but it works good and thats the most important thing =P
So here we come to the tutorial:
Code:
#RequireAdmin [COLOR="YellowGreen"];vista do not have to run as admin[/COLOR] #Region ;**** Directives created by AutoIt3Wrapper_GUI **** #AutoIt3Wrapper_outfile=..\..\..\Programme\AutoLoginv0.37.exe #EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
Code:
#include <ButtonConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <GUIListBox.au3> #include <StaticConstants.au3> #include <WindowsConstants.au3> #include <memory2.au3> #include <GUIConstants.au3>
Code:
$file = @ScriptDir & "\login.ini" $Form2 = GUICreate("AutoLogin by HideAndSeek", 341, 417, 249, 133) $Group1 = GUICtrlCreateGroup("Deine Daten!", 8, 8, 169, 105) $Label1 = GUICtrlCreateLabel("ID", 152, 32, 15, 17) $namegui = GUICtrlCreateInput(IniRead($file,"Allgemein", "Name",""), 24, 32, 121, 21) $pwgui = GUICtrlCreateInput(IniRead($file,"Allgemein", "",""), 24, 64, 121, 21) $Label2 = GUICtrlCreateLabel("PW", 152, 64, 22, 17) GUICtrlCreateGroup("", -99, -99, 1, 1) $Group2 = GUICtrlCreateGroup("PC Einstellungen", 184, 8, 145, 105) $Label7 = GUICtrlCreateLabel("Pc-Geschwindigkeit", 200, 32, 98, 17) $leistunggui = GUICtrlCreateInput(IniRead($file,"Allgemein", "Leistung",""), 192, 88, 41, 21) $Label10 = GUICtrlCreateLabel("Sekunden bis zum Start von", 192, 64, 137, 17) $Label11 = GUICtrlCreateLabel("Silkroad", 240, 80, 42, 17) GUICtrlCreateGroup("", -99, -99, 1, 1) $Group3 = GUICtrlCreateGroup("Show/Hide Silkroad", 8, 176, 169, 97) $hidesrogui = GUICtrlCreateButton("Hide Silkroad", 16, 200, 153, 17, $WS_GROUP) $showsrogui = GUICtrlCreateButton("Show Silkroad", 16, 224, 153, 17, $WS_GROUP) $exitsrogui = GUICtrlCreateButton("Exit Silkroad", 16, 248, 153, 17, $WS_GROUP) GUICtrlCreateGroup("", -99, -99, 1, 1) $Group4 = GUICtrlCreateGroup("Programmbefehle", 8, 272, 169, 137) $startgui = GUICtrlCreateButton("Start AutoLogin F5", 16, 296, 153, 25, $WS_GROUP) $stopgui = GUICtrlCreateButton("Stop AutoLogin F6", 16, 328, 153, 25, $WS_GROUP) $exitgui = GUICtrlCreateButton("Exit Tool F7", 16, 360, 153, 17, $WS_GROUP) $showgui = GUICtrlCreateButton("Show the Tool F8", 16, 384, 153, 17, 0) GUICtrlCreateGroup("", -99, -99, 1, 1) $Group5 = GUICtrlCreateGroup("Programmeinstellungen", 184, 112, 145, 161) $checked = IniRead($file, "Allgemein", "MitSRO", "") $mitsrogui = GUICtrlCreateCheckbox("Mit Silkroad starten?", 192, 136, 113, 17) If $checked = "1" Then GUICtrlSetState($mitsrogui, $GUI_CHECKED) EndIf $Label3 = GUICtrlCreateLabel("ggf. Pfad angeben!", 192, 152, 95, 17) $pfadgui = GUICtrlCreateInput("", 192, 176, 121, 21) $searchgui = GUICtrlCreateButton("Durchsuchen", 192, 200, 121, 17, $WS_GROUP) $reconnectgui = GUICtrlCreateInput(IniRead($file, "Allgemein", "Reconnect", ""), 192, 232, 33, 21, BitOR($ES_AUTOHSCROLL,$ES_NUMBER)) $Label8 = GUICtrlCreateLabel("Reconnect nach", 232, 224, 84, 17) $Label9 = GUICtrlCreateLabel("X Sekunden", 232, 240, 63, 17) GUICtrlCreateGroup("", -99, -99, 1, 1) $Group6 = GUICtrlCreateGroup("Weiteres", 184, 272, 145, 137) $Label5 = GUICtrlCreateLabel("For more Infos", 216, 368, 71, 17) $linkgui = GUICtrlCreateLabel("KLICK HERE!", 216, 384, 70, 17) GUICtrlSetFont(-1, 8, 400, 4, "MS Sans Serif") GUICtrlSetColor(-1, 0x0000FF) GUICtrlSetCursor (-1, 0) $maxchar=IniRead($file, "Allgemein", "MaxChar", "") $maxchargui = GUICtrlCreateCombo(IniRead($file, "Allgemein", "MaxChar", ""), 192, 296, 49, 25) If $maxchar="1" Then GUICtrlSetData($maxchargui, "2|3|4") ElseIf $maxchar="2" Then GUICtrlSetData($maxchar, "1|3|4") ElseIf $maxchar="3" Then GUICtrlSetData($maxchar, "1|2|4") ElseIf $maxchar="4" Then GUICtrlSetData($maxchar, "1|2|3") EndIf $charposgui = GUICtrlCreateCombo(IniRead($file, "Allgemein", "Charpos", ""), 192, 336, 49, 25) If $charposgui="1" Then GUICtrlSetData($charposgui, "2|3|4") ElseIf $charposgui="2" Then GUICtrlSetData($charposgui, "1|3|4") ElseIf $charposgui="3" Then GUICtrlSetData($charposgui, "1|2|4") ElseIf $charposgui="4" Then GUICtrlSetData($charposgui, "1|2|3") EndIf $Label4 = GUICtrlCreateLabel("Anz. von Chars", 248, 296, 76, 17) $Label6 = GUICtrlCreateLabel("Char. Position", 248, 336, 69, 17) GUICtrlCreateGroup("", -99, -99, 1, 1) $Group7 = GUICtrlCreateGroup("Server", 8, 112, 169, 65) $changeservergui = GUICtrlCreateCheckbox("Server wechseln?", 56, 120, 113, 17) $servergui = GUICtrlCreateCombo(IniRead($file,"Allgemein","Server",""), 32, 144, 121, 25) GUICtrlSetData($servergui, "Venice|Greece|Alps|Olympus|Tibet|RedSea|Pacific|Oasis|Odin|Hercules|Alexander|Saturn|Venus|Mars|Uranus|Mercury|Poseidon|Zeus|Persia|Eldorado|Sparta|Rome|Neptune|Hera (New)|Gaia (New)|Eos (New)|Phoenix (New)|Ares (New)|Iris (New)|Titan (New)|Apollo (New)|Xian|Aege|Troy|Athens|Oasis") GUICtrlCreateGroup("", -99, -99, 1, 1) GUISetState(@SW_SHOW)
well this is the GUI! U can easily create a GUI with the KODA - Tool (google it)
The tool got a save function, with "$checked = IniRead($file, "Allgemein", "MitSRO", "")" u can save the Value that is in the Ini-File (just a config File, like a .txt-file) , so u just read out the Value and put it in the InputBox(ill explain later, how u write the things into the .ini-file.
Code:
HotKeySet("{F5}", 'start') HotKeySet("{F6}", 'stop') HotKeySet("{F7}", '_exit') HotKeySet("{F8}", 'infront')
So lets move to the Functions =)
First i pick out the "simple" functions =P , Ill comment it in the Source!
Code:
Func link() ShellExecute("http://forum.**********/silkroad-online/sro-bots-guides-hacks/108989-autologin-v0-37/") EndFunc [COLOR="YellowGreen"];This functions starts FireFox and connects to the Link [/COLOR] Func stop() exit EndFunc [COLOR="YellowGreen"];Exits the tool [/COLOR] Func infront() WinActivate(@ScriptName) EndFunc [COLOR="YellowGreen"];Activates the tool[/COLOR] Func _exit() Exit EndFunc [COLOR="YellowGreen"];Exits the tool [/COLOR] Func hide() WinSetState("SRO_Client", "", @SW_HIDE) EndFunc [COLOR="YellowGreen"]; Hides all Windows with the name "SRO_Client"[/COLOR] Func show() WinSetState("SRO_Client", "", @SW_SHOW) EndFunc [COLOR="YellowGreen"];Shows all hidden Windows with the name "SRO_Client"[/COLOR] Func exitsro() If ProcessExists("sro_client.exe") Then If MsgBox(292, "Achtung!", "Willst du Silkroad wirklich beenden?") = 6 Then ProcessClose("sro_client.exe") EndIf EndIf EndFunc [COLOR="YellowGreen"];If u klick "Exit SRO" a Msg Box with "Yes" and "no" will appear, if u click "yes" then ProcessClose("sro_client.exe")(selfexplaining)[/COLOR] Func durchsuchen() $pfad = FileOpenDialog("Silkroad Launcher ausw鄣len!", @DesktopDir, "Silkroad Launcher (*.exe)", 1) If Not @error Then GUICtrlSetData($pfadgui, $pfad) EndIf EndFunc[COLOR="YellowGreen"] ;This(FileOpenDialog) opens the Window where u can Select ;the Silkroad launcher[/COLOR]
Ok, so lets come to the Main Function:
Code:
Func start() [COLOR="YellowGreen"];If u click the Start-Button the value of the variable $start changes to "true"[/COLOR] $start=true EndFunc While 1 ; if $start=true Then [COLOR="YellowGreen"];Self explaining[/COLOR] $start=false ; $i = 0 $pfad = GUICtrlRead($pfadgui) [COLOR="YellowGreen"]; Selfexplaining [/COLOR] $name = GUICtrlRead($namegui) $pw = GUICtrlRead($pwgui) $leistung = GUICtrlRead($leistunggui) $reconnect = GUICtrlRead($reconnectgui) $charpos=GUICtrlRead($charposgui) $maxchar=GUICtrlRead($maxchargui) $server=GUICtrlRead($servergui) $file = @ScriptDir & "\login.ini" IniWrite($file, "Allgemein", "Name", $name) ;[COLOR="YellowGreen"]This writes the things into the Ini-File so that u do not need to fill in it the whole time[/COLOR] IniWrite($file, "Allgemein", "PW", $pw) IniWrite($file, "Allgemein", "Leistung", $leistung) IniWrite($file, "Allgemein", "Pfad", $pfad) IniWrite($file, "Allgemein", "Reconnect", $reconnect) IniWrite($file, "Allgemein", "Charpos", $charpos) IniWrite($file, "Allgemein", "MaxChar", $maxchar) IniWrite($file, "Allgemein", "Server", $server) [COLOR="YellowGreen"];All the coming If-Functions are checking if u filled in all Input Boxes right[/COLOR] if $charpos > $maxchar Then MsgBox(0,"Falsche Charakter Position!", "Deine Charakterposition kann nichts h鐬er als deine Zahl an Charakteren sein!") EndIf if $maxchar > "4" Then MsgBox(0, "Zu hohe Anzahl von Chars!", "Du kannst nicht mehr als 4 Charaktere haben >.^") EndIf if $charpos = "0" Then MsgBox(0,"Falsche CharPosition","Du kannst nur die Positionen 1-4 belegen") EndIf If $charpos > "5" Then MsgBox(0,"Falsche CharPosition", "Du kannst nur die Positionen 1-4 belegen") EndIf If $leistung = "" Then $leistung = "25" EndIf If $name = "" Then MsgBox(0, "Keine ID", "Du musst eine ID angeben!") EndIf If $pw = "" Then MsgBox(0, "Kein PW", "Du musst ein PW angeben!") EndIf If $reconnect = "" Then $reconnect = "7" EndIf If GUICtrlRead($changeservergui) = $GUI_CHECKED Then RegWrite("HKEY_CURRENT_USER\Software\Joymax\Silkroad","RECENTSERVER","REG_SZ",$server) EndIf [COLOR="YellowGreen"];This changes the Server u want to connect, it just writes the new Server into that file, were Silkroad is saving it.[/COLOR] if $mitsrogui = $GUI_CHECKED Then Run($pfad) ;Runs Silkroad WinWaitActive("Silkroad Online Launcher") [COLOR="YellowGreen"];Waits for the ;Launcher[/COLOR] If WinActive("Silkroad Online Launcher") = 0 Then [COLOR="YellowGreen"];Activates it until its activated[/COLOR] Do WinActivate("Silkroad Online Launcher") Until WinActive("Silkroad Online Launcher") = 1 EndIf Sleep(500) [COLOR="YellowGreen"];this is the first thing u maybe do not understand, so start the Silkroad Launcher and the AutoIt window info tool in The tool change to "Summary" and go with ure mouse of the "Start"-Button in the Silkroad online launcher , then u will see "[CLASS:Button; INSTANCE:1]" at the "Advanced (Class), so here the tool clicks on the "Start" button of your silkroad launcher[/COLOR] Sleep(2000) ControlClick("Silkroad Online Launcher", "", "[CLASS:Button; INSTANCE:1]") WinWait("SRO_Client") [COLOR="YellowGreen"];it waits for silkroad to open [/COLOR] Sleep($leistung*1000) [COLOR="YellowGreen"]; then it waits for the time that [/COLOR] Sleep(500) [COLOR="YellowGreen"];tabs to the PW Input[/COLOR] ControlSend("[CLASS:CLIENT]", "", "Edit1", "{TAB}") Sleep(500) [COLOR="YellowGreen"]; sends the PW[/COLOR] ControlSend("[CLASS:CLIENT]", "", "Edit1", $pw) Sleep(100) [COLOR="YellowGreen"];If all this is ready , then the Function "EnterSenden" (in english: ;SendingEnter) is called.[/COLOR] EnterSenden() Else EnterSenden() EndIf EndIf WEnd Func EnterSenden() ;Sends enter until ure logged in $srohandle = WinGetHandle("[CLASS:CLIENT]") $pidsro = Wingetprocess($srohandle) $loginmemory = _MemoryOpen($pidsro) [COLOR="YellowGreen"]; First the memory needs to be open, now the ;Programm checks for the ;adress to become 1, an adress is there to save some values, in this adress ;the value 0 stands for "logged out" and 1 ist for "logged in" , so While the adress is 0 (logged out) it sends enter, but if the adress is 1 then the tool goes on. the function _char() is called and the "Beep" lets u hear a sound so that u know ure logged in ;)[/COLOR] While _MemoryRead(0xF5315C, $loginmemory) <> 1 ControlSend("[CLASS:CLIENT]","","Edit1", "{ENTER}") Sleep($reconnect*1000) If $i=1 Then return 1 endif WEnd if ProcessExists("sro_client.exe") Then _char() Beep(350,500) return 1 Else $start=true return 1 endif EndFunc [COLOR="YellowGreen"];so lets move to the function _char()[/COLOR] Func _char() [COLOR="YellowGreen"];This function selects the Char u have choosen(not the name- the position) -the function works with Pixels and not with adresses[/COLOR] Sleep(2000) $dw=@DesktopWidth $dh=@DesktopHeight $charpos=GUICtrlRead($charposgui) $charanz=GUICtrlRead($maxchargui) WinActivate("[CLASS:CLIENT]") WinWaitActive("[CLASS:CLIENT]") [COLOR="YellowGreen"];The tool Clicks at $charpos* ($dw/($charanz+1)),$dh/2, if u think a bit logical u should understand that , ;if not -> ask[/COLOR] ControlClick("[CLASS:CLIENT]","",$charpos*($dw/($charanz+1)),$dh/2) Sleep(3000) ControlClick("[CLASS:CLIENT]","",4/5*$dw,9/10*$dh) [COLOR="YellowGreen"]; the next ControlClick clicks on the Start button right down at the login ;screen[/COLOR] EndFunc
I know the tutorial is not very good, but i dont want to do an AutoIt tutorial^^
if u have any questions -> ASK
Ill post later how to find out the Adress, that is used to know when u are Logged in!
Please post suggestions for the tutorial and correct my very bad english
Ill edit this tutorials some times, and will also upload new versions here, so the whole source for u:
Code:
#RequireAdmin #Region ;**** Directives created by AutoIt3Wrapper_GUI **** #AutoIt3Wrapper_outfile=..\..\..\AutoLoginv0.38.exe #EndRegion ;**** Directives created by AutoIt3Wrapper_GUI **** #include <ButtonConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <GUIListBox.au3> #include <StaticConstants.au3> #include <WindowsConstants.au3> #include <memory2.au3> #include <GUIConstants.au3> #include <memory2.au3> $file = @ScriptDir & "\login.ini" $Form2 = GUICreate("AutoLogin by HideAndSeek", 341, 417, 249, 133) $Group1 = GUICtrlCreateGroup("Deine Daten!", 8, 8, 169, 105) $Label1 = GUICtrlCreateLabel("ID", 152, 32, 15, 17) $namegui = GUICtrlCreateInput(IniRead($file,"Allgemein", "Name",""), 24, 32, 121, 21) $pwgui = GUICtrlCreateInput(IniRead($file,"Allgemein", "PW",""), 24, 64, 121, 21) $Label2 = GUICtrlCreateLabel("PW", 152, 64, 22, 17) GUICtrlCreateGroup("", -99, -99, 1, 1) $Group2 = GUICtrlCreateGroup("PC Einstellungen", 184, 8, 145, 105) $Label7 = GUICtrlCreateLabel("Pc-Geschwindigkeit", 200, 32, 98, 17) $leistunggui = GUICtrlCreateInput(IniRead($file,"Allgemein", "Leistung",""), 192, 88, 41, 21) $Label10 = GUICtrlCreateLabel("Sekunden bis zum Start von", 192, 64, 137, 17) $Label11 = GUICtrlCreateLabel("Silkroad", 240, 80, 42, 17) GUICtrlCreateGroup("", -99, -99, 1, 1) $Group3 = GUICtrlCreateGroup("Show/Hide Silkroad", 8, 176, 169, 97) $hidesrogui = GUICtrlCreateButton("Hide Silkroad", 16, 200, 153, 17, $WS_GROUP) $showsrogui = GUICtrlCreateButton("Show Silkroad", 16, 224, 153, 17, $WS_GROUP) $exitsrogui = GUICtrlCreateButton("Exit Silkroad", 16, 248, 153, 17, $WS_GROUP) GUICtrlCreateGroup("", -99, -99, 1, 1) $Group4 = GUICtrlCreateGroup("Programmbefehle", 8, 272, 169, 137) $startgui = GUICtrlCreateButton("Start AutoLogin F5", 16, 296, 153, 25, $WS_GROUP) $stopgui = GUICtrlCreateButton("Stop AutoLogin F6", 16, 328, 153, 25, $WS_GROUP) $exitgui = GUICtrlCreateButton("Exit Tool F7", 16, 360, 153, 17, $WS_GROUP) $showgui = GUICtrlCreateButton("Show the Tool F8", 16, 384, 153, 17, 0) GUICtrlCreateGroup("", -99, -99, 1, 1) $Group5 = GUICtrlCreateGroup("Programmeinstellungen", 184, 112, 145, 161) $checked = IniRead($file, "Allgemein", "MitSRO", "") $mitsrogui = GUICtrlCreateCheckbox("Mit Silkroad starten?", 192, 136, 113, 17) If $checked = "1" Then GUICtrlSetState($mitsrogui, $GUI_CHECKED) EndIf $Label3 = GUICtrlCreateLabel("ggf. Pfad angeben!", 192, 152, 95, 17) $pfadgui = GUICtrlCreateInput(IniRead($file, "Allgemein", "Pfad", ""), 192, 176, 121, 21) $searchgui = GUICtrlCreateButton("Durchsuchen", 192, 200, 121, 17, $WS_GROUP) $reconnectgui = GUICtrlCreateInput(IniRead($file, "Allgemein", "Reconnect", ""), 192, 232, 33, 21, BitOR($ES_AUTOHSCROLL,$ES_NUMBER)) $Label8 = GUICtrlCreateLabel("Reconnect nach", 232, 224, 84, 17) $Label9 = GUICtrlCreateLabel("X Sekunden", 232, 240, 63, 17) GUICtrlCreateGroup("", -99, -99, 1, 1) $Group6 = GUICtrlCreateGroup("Weiteres", 184, 272, 145, 137) $Label5 = GUICtrlCreateLabel("For more Infos", 216, 368, 71, 17) $linkgui = GUICtrlCreateLabel("KLICK HERE!", 216, 384, 70, 17) GUICtrlSetFont(-1, 8, 400, 4, "MS Sans Serif") GUICtrlSetColor(-1, 0x0000FF) GUICtrlSetCursor (-1, 0) $maxchar=IniRead($file, "Allgemein", "MaxChar", "") $maxchargui = GUICtrlCreateCombo(IniRead($file, "Allgemein", "MaxChar", ""), 192, 296, 49, 25) If $maxchar="1" Then GUICtrlSetData($maxchargui, "2|3|4") ElseIf $maxchar="2" Then GUICtrlSetData($maxchar, "1|3|4") ElseIf $maxchar="3" Then GUICtrlSetData($maxchar, "1|2|4") ElseIf $maxchar="4" Then GUICtrlSetData($maxchar, "1|2|3") EndIf $charposgui = GUICtrlCreateCombo(IniRead($file, "Allgemein", "Charpos", ""), 192, 336, 49, 25) If $charposgui="1" Then GUICtrlSetData($charposgui, "2|3|4") ElseIf $charposgui="2" Then GUICtrlSetData($charposgui, "1|3|4") ElseIf $charposgui="3" Then GUICtrlSetData($charposgui, "1|2|4") ElseIf $charposgui="4" Then GUICtrlSetData($charposgui, "1|2|3") EndIf $Label4 = GUICtrlCreateLabel("Anz. von Chars", 248, 296, 76, 17) $Label6 = GUICtrlCreateLabel("Char. Position", 248, 336, 69, 17) GUICtrlCreateGroup("", -99, -99, 1, 1) $Group7 = GUICtrlCreateGroup("Server", 8, 112, 169, 65) $serverchecked = IniRead($file, "Allgemein", "ChangeServer", "") $changeservergui = GUICtrlCreateCheckbox("Server wechseln?", 56, 120, 113, 17) If $serverchecked = "1" Then GUICtrlSetState($changeservergui, $GUI_CHECKED) EndIf $servergui = GUICtrlCreateCombo(IniRead($file,"Allgemein","Server",""), 32, 144, 121, 25) GUICtrlSetData($servergui, "Venice|Greece|Alps|Olympus|Tibet|RedSea|Pacific|Oasis|Odin|Hercules|Alexander|Saturn|Venus|Mars|Uranus|Mercury|Poseidon|Zeus|Persia|Eldorado|Sparta|Rome|Neptune|Hera (New)|Gaia (New)|Eos (New)|Phoenix (New)|Ares (New)|Iris (New)|Titan (New)|Apollo (New)|Xian|Aege|Troy|Athens|Oasis") GUICtrlCreateGroup("", -99, -99, 1, 1) GUISetState(@SW_SHOW) HotKeySet("{F5}", '_start') HotKeySet("{F6}", '_stop') HotKeySet("{F7}", '_exit') HotKeySet("{F8}", '_infront') Opt('GUIOnEventMode', 1) Opt("GUICloseOnESC", 0) Opt("TrayAutoPause",0) GUICtrlSetOnEvent($linkgui, '_link') GUICtrlSetOnEvent($searchgui, '_durchsuchen') GUICtrlSetOnEvent($startgui, '_start') GUICtrlSetOnEvent($stopgui, '_stop') GUISetOnEvent($GUI_EVENT_CLOSE, '_exit') GUICtrlSetOnEvent($hidesrogui, '_hide') GUICtrlSetOnEvent($showsrogui, '_show') GUICtrlSetOnEvent($exitsrogui, '_exitsro') GUICtrlSetOnEvent($exitgui, '_exit') Global $i Global $reconnect Global $sro Global $start=false Func _start() $start=true EndFunc Func _char() Beep(500, 500) Beep(400, 500) Beep(300, 500) Beep(200, 500) Beep(100, 500) Beep(50, 500) Sleep(2000) $dw=@DesktopWidth $dh=@DesktopHeight $charpos=GUICtrlRead($charposgui) $charanz=GUICtrlRead($maxchargui) $handle = WinGetHandle("[CLASS:CLIENT]") $sropid = Wingetprocess($handle) WinActivate($sropid) WinWaitActive($sropid) ControlClick($sropid,"",$charpos*($dw/($charanz+1)),$dh/2) Sleep(3000) ControlClick($sropid,"",4/5*$dw,9/10*$dh) EndFunc Func _EnterSenden() $srohandle = WinGetHandle("sro_client.exe") $pidsro = Wingetprocess($srohandle) $loginmemory = _MemoryOpen($pidsro) While _MemoryRead(0xF5315C, $loginmemory) <> 1 ControlSend("[CLASS:CLIENT]", "", "Edit1", "{ENTER}") If ProcessExists("sro_client.exe") Then Sleep($reconnect*1000) Else _start() EndIf If $i=1 Then return 1 endif WEnd if ProcessExists("sro_client.exe") Then _char() return 1 Else $start=true return 1 endif EndFunc Func _link() ShellExecute("http://forum.**********/silkroad-online/sro-bots-guides-hacks/108989-autologin-v0-38/") EndFunc Func _stop() $i = 1 EndFunc Func _infront() WinActivate("AutoLogin by HideAndSeek") EndFunc Func _exit() Exit EndFunc Func _hide() $srohandle = WinGetHandle("[CLASS:CLIENT]") $sropid = Wingetprocess($srohandle) WinSetState($sropid, "", @SW_HIDE) EndFunc Func _show() $srohandle = WinGetHandle("[CLASS:CLIENT]") $sropid = Wingetprocess($srohandle) WinSetState($sropid, "", @SW_SHOW) EndFunc Func _exitsro() $srohandle = WinGetHandle("[CLASS:CLIENT]") $sropid = Wingetprocess($srohandle) If ProcessExists($sropid) Then If MsgBox(292, "Achtung!", "Willst du Silkroad wirklich beenden?") = 6 Then ProcessClose($sropid) EndIf EndIf EndFunc Func _durchsuchen() $pfad = FileOpenDialog("Silkroad Launcher ausw鄣len!", @DesktopDir, "Silkroad Launcher (*.exe)", 1) If Not @error Then GUICtrlSetData($pfadgui, $pfad) EndIf EndFunc While 1 if $start=true Then $start=false $i = 0 $pfad = GUICtrlRead($pfadgui) $name = GUICtrlRead($namegui) $pw = GUICtrlRead($pwgui) $leistung = GUICtrlRead($leistunggui) $reconnect = GUICtrlRead($reconnectgui) $charpos=GUICtrlRead($charposgui) $maxchar=GUICtrlRead($maxchargui) $server=GUICtrlRead($servergui) If GUICtrlRead($changeservergui)=$GUI_CHECKED Then $changeserver= "1" Else $changeserver= "0" EndIf If GUICtrlRead($mitsrogui)=$GUI_CHECKED Then $mitsro= "1" Else $mitsro= "0" EndIf $file = @ScriptDir & "\login.ini" IniWrite($file, "Allgemein", "Name", $name) IniWrite($file, "Allgemein", "PW", $pw) IniWrite($file, "Allgemein", "Leistung", $leistung) IniWrite($file, "Allgemein", "Pfad", $pfad) IniWrite($file, "Allgemein", "Reconnect", $reconnect) IniWrite($file, "Allgemein", "Charpos", $charpos) IniWrite($file, "Allgemein", "MaxChar", $maxchar) IniWrite($file, "Allgemein", "Server", $server) IniWrite($file, "Allgemein", "MitSRO", $mitsro) IniWrite($file, "Allgemein", "ChangeServer", $changeserver) if $charpos > $maxchar Then MsgBox(0,"Falsche Charakter Position!", "Deine Charakterposition kann nichts h鐬er als deine Zahl an Charakteren sein!") EndIf if $maxchar > "4" Then MsgBox(0, "Zu hohe Anzahl von Chars!", "Du kannst nicht mehr als 4 Charaktere haben >.^") EndIf if $charpos = "0" Then MsgBox(0,"Falsche CharPosition","Du kannst nur die Positionen 1-4 belegen") EndIf If $charpos > "5" Then MsgBox(0,"Falsche CharPosition", "Du kannst nur die Positionen 1-4 belegen") EndIf If $leistung = "" Then $leistung = "25" EndIf if $mitsrogui = $GUI_CHECKED Then If $name = "" Then MsgBox(0, "Keine ID", "Du musst eine ID angeben!") EndIf If $pw = "" Then MsgBox(0, "Kein PW", "Du musst ein PW angeben!") EndIf EndIf If $reconnect = "" Then $reconnect = "7" EndIf If GUICtrlRead($changeservergui) = $GUI_CHECKED Then RegWrite("HKEY_CURRENT_USER\Software\Joymax\Silkroad","RECENTSERVER","REG_SZ",$server) EndIf if GUICtrlRead($mitsrogui) = $GUI_CHECKED Then Run($pfad) WinWaitActive("[CLASS:#32770]") If WinActive("[CLASS:#32770]") = 0 Then Do WinActivate("[CLASS:#32770]") Until WinActive("[CLASS:#32770]") = 1 EndIf Sleep(500) ControlClick("[CLASS:#32770]", "", "[CLASS:Button; INSTANCE:18]") Sleep(5000) ControlClick("[CLASS:#32770]", "", "[CLASS:Button; INSTANCE:1]") Sleep($leistung*1000) ControlSend("[CLASS:CLIENT]", "", "Edit1", "x") Sleep(500) ControlSend("[CLASS:CLIENT]", "", "Edit1", $name) Sleep(500) ControlSend("[CLASS:CLIENT]", "", "Edit1", "{TAB}") Sleep(500) ControlSend("[CLASS:CLIENT]", "", "Edit1", $pw) Sleep(100) _EnterSenden() Else _EnterSenden() EndIf EndIf $handle = WinGetHandle("[CLASS:CLIENT]") $sropid = Wingetprocess($handle) $memory = _MemoryOpen($sropid) If _MemoryRead(0x1267F2, $memory) = 1 Then _MemoryClose($memory) _start() EndIf WEnd