Register for your free account! | Forgot your password?

You last visited: Today at 04:33

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



LoL Bot Hilfe

Discussion on LoL Bot Hilfe within the League of Legends forum part of the Popular Games category.

Reply
 
Old   #1
 
golle12's Avatar
 
elite*gold: 29
Join Date: Aug 2011
Posts: 640
Received Thanks: 493
Smile LoL Bot Hilfe

Hier ist das Script :
PHP Code:
Global $Paused
$passwort 
InputBox ("Passwort Manager","Bitte geben sie das Passwort ein!","","*")
 If 
$passwort "" Then
    MsgBox
(64"Passwort Manager""Das Passwort wurde richtig eingegeben!",1)
Else
 
MsgBox(16"ERROR 405""Zugriff Verweigert! " &@CRLF" Bitte geben sie das Passwort richtig ein!",2)
Exit
 EndIf
#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_Res_requestedExecutionLevel=asInvoker
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#NoTrayIcon
#include <EditConstants.au3>
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
Opt("GUIOnEventMode"1)
$Form1 GUICreate("League of Legends afk Bot made by "418227196126)
$Group1 GUICtrlCreateGroup("LOL afk Bot"00417225)
$Button1 GUICtrlCreateButton("Start"81764341)
$Button2 GUICtrlCreateButton("Exit"561767541)
$Label1 GUICtrlCreateLabel("Bot made by "14419226624)
GUICtrlSetFont(-1128002"MS Sans Serif")
$Label2 GUICtrlCreateLabel("F2: Start"16166120)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Label3 GUICtrlCreateLabel("F3: Login"16406720)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Pic1 GUICtrlCreatePic("C:\Users\Privat\Desktop\Afk Bot\Pentakill.jpg"968321161)
$Button3 GUICtrlCreateButton("Go LOL"81367333)
$Label4 GUICtrlCreateLabel("F5: Stop"16886120)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Label5 GUICtrlCreateLabel("F7: Pause"161127320)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Label6 GUICtrlCreateLabel("F4: Spiel"16646520)
GUICtrlSetFont(-1108000"MS Sans Serif")
GUICtrlCreateGroup("", -99, -9911)
GUISetState(@SW_SHOW)
GUISetOnEvent($GUI_EVENT_CLOSE"_Exit")
GUICtrlSetOnEvent($Button1"_Start")
GUICtrlSetOnEvent($Button2"_Exit")
GUICtrlSetOnEvent($Button3"_Login")

While 
1
    $nMsg 
GUIGetMsg()
    Switch 
$nMsg
        
Case $GUI_EVENT_CLOSE
            
Exit
        Case 
$Button1
            _Start
()
        Case 
$Button2
            _Exit
()
        Case 
$Button3
            _Login
()
    EndSwitch
    
HotKeySet("{F2}","Start")
    
HotKeySet("{F3}","Login")
    
HotKeySet("{F4}","Start_Spiel")
    
HotKeySet("{F5}","Stop")
    
HotKeySet("{F7}""TogglePause")
WEnd

Func Login
()
$acountname ""
$passwort ""
 
If Run("C:\Riot Games\League of Legends\lol.launcher.exe"Then
MsgBox
(64,"League of Legends Launcher!","Launcher wird gestartet " &@CRLF" und wirst eingeloggt!",12)
 Else
MsgBox(16,"ERROR 426!","League of Legends nicht insatlliert " &@CRLF" bitte installieren sie LOL!",6)
Exit
EndIf
Sleep(1500)
MouseClick("left"9426301)
Sleep(13000)
MouseClick("left"3133022)
Sleep(1000)
Send("{BACKSPACE 13}")
Sleep(1000)
Send ($acountname)
MouseClick("left",286,358,1)
Sleep(1500)
Send($passwort)
Sleep(2500)
MouseClick("left",406,428,1)
Sleep(6000)
MsgBox(64,"Erfolgreich","Login erfolgreich",2)
EndFunc

Func _Login
()
$acountname ""
$passwort ""
 
If Run("C:\Riot Games\League of Legends\lol.launcher.exe"Then
MsgBox
(64,"League of Legends Launcher!","Launcher wird gestartet " &@CRLF" und wirst eingeloggt!",12)
 Else
MsgBox(16,"ERROR 426!","League of Legends nicht insatlliert " &@CRLF" bitte installieren sie LOL!",6)
Exit
EndIf
Sleep(1500)
MouseClick("left"9426301)
Sleep(13000)
MouseClick("left"3133022)
Sleep(1000)
Send("{BACKSPACE 13}")
Sleep(1000)
Send ($acountname)
MouseClick("left",286,358,1)
Sleep(1500)
Send($passwort)
Sleep(2500)
MouseClick("left",406,428,1)
Sleep(6000)
MsgBox(64,"Erfolgreich","Login erfolgreich",2)
EndFunc

Func Start
()
MsgBox(64,"Erfolg","AFK Bot wird gestartet",6)
While 
1
Sleep
(10)
Sleep(3000)
MouseClick("right",1189,695,1)
Sleep(9000)
MouseClick("right",940,427,1)
Sleep(9000)
MouseClick("right",717,429,1)
Sleep(8000)
MouseClick("right",702,421,1)
Sleep(8000)
MouseClick("right",703,429,1)
Sleep(8000)
MouseClick("right",721,427,1)
Sleep(6000)
MouseClick("right",696,437,1)
Sleep(7000)
MouseClick("right",674,434,1)
Sleep(10000)
Send("b")
Sleep(200)
WEnd
EndFunc

Func _Start
()
MsgBox(64,"Erfolg","AFK Bot wird gestartet",6)
While 
1
Sleep
(3000)
MouseClick("right",1189,695,1)
Sleep(9000)
MouseClick("right",940,427,1)
Sleep(9000)
MouseClick("right",717,429,1)
Sleep(8000)
MouseClick("right",702,421,1)
Sleep(8000)
MouseClick("right",703,429,1)
Sleep(8000)
MouseClick("right",721,427,1)
Sleep(6000)
MouseClick("right",696,437,1)
Sleep(7000)
MouseClick("right",674,434,1)
Sleep(10000)
Send("b")
Sleep(200)
WEnd
EndFunc

Func Start_Spiel
()
MsgBox(64,"Bot Game","/Bot Game\/Kluft der Beschwörer\/Anfänger\",5)
Sleep(100)
MouseClick("
left",685,45,1)
Sleep(1999)
MouseClick("
left",380,173,1)
Sleep(100)
MouseClick("
left",587,145,1)
Sleep(100)
MouseClick("
left",759,152,1)
Sleep(100)
MouseClick("
left",956,146,1)
Sleep(100)
MouseClick("
left",796,682,1)
Sleep(1000)
While 1
$Annehmen = PixelSearch(541,417,635,442,0x224C7F,0)
If IsArray(
$Annehmen) Then
MouseClick("
left",585,431,1)
EndIf
Sleep(100)
WEnd
Sleep(4000)
$Teemo = PixelSearch(1,1)
$Darius = PixelSearch(1,1)
$Akali = PixelSearch(1,1)
$Morgana = PixelSearch(1,1)
$Shaco = PixelSearch(1,1)
$Garen = PixelSearch(1,1)
$Vaigar = PixelSearch(1,1)
$Teemo= InputBox("Champ Auswahl","Bitte wähle dir einen " &@CRLF& " von den Champs aus:" &@CRLF& " -Teemo" &@CRLF& " -Darius" &@CRLF& " -Akali" &@CRLF& " -Morgana" &@CRLF& " -Shaco" &@CRLF& " -Garen" &@CRLF& " -Vaigar")
$Ausgabe =
If IsArray(
$Teemo) Then
MouseMove(
$Teemo[0],$Teemo[1],0)
MouseClick("
left")
EndFunc

Func _Exit()
Exit
EndFunc

Func Stop()
Exit
EndFunc

Func TogglePause()
    
$Paused = NOT $Paused
    While 
$Paused
        sleep(100)
        ToolTip("
Bot wird pausiert!",0,0)
    WEnd
    ToolTip("
Pause beendet!",0,0)
    Sleep(1500)
    ToolTip("")
EndFunc 
################################################## ##
Und zwar möchte ich gerne das bei der Inputbox wenn ich die Namen reinschreibe zB. Teemo,dass dann per pixelsearch sucht und auf ihn klickt ich freue mich über jede Hilfe.
golle12 is offline  
Old 02/18/2013, 11:40   #2
 
Gotoxy's Avatar
 
elite*gold: 35
Join Date: Aug 2007
Posts: 460
Received Thanks: 114
ganz im ernst? totaler schrott.

entweder du arbeitest komplett per IMG search und lässt den msg box mist erstmal weg(mach ne richtige consolenausgabe das ist beudent besser und nicht so hässlich)

solltest du es mit img search nicht hinbekommen benutze wenigstens soviel grips und justtiere die coords, wei ldie sich je nach fenstergöße ändern können...

daher,belese dich in image search kay?


btw..deine exit und stop function sind beide das selbe...

mach die pause nicht mit 100 sondern mit 1000...

alg sind 100er sleeps recht niedrig,würde min immer 500-750 nehmen

les doch erstmal ein paar autoit tuts, einige gute zum thema bots findest d sogar hier bei epvp in der autoit sektion...
Gotoxy is offline  
Old 02/18/2013, 17:22   #3
 
golle12's Avatar
 
elite*gold: 29
Join Date: Aug 2011
Posts: 640
Received Thanks: 493
es tut mir leid das ich es nicht so richtig gemacht habe das ist mein erster richtiger Bot an dem ich mich versuchen wollte aber danke für die Informationen. Und was ich noch wollte st das mit der Stop funktion und zwar soll er die Start Funktion aufheben da weiß ich nicht wie ich das machen soll so dass es auch funktioniert. Freue mich auch schon auf die nächste Antwort
Danke
golle12 is offline  
Old 02/18/2013, 18:21   #4
 
Gotoxy's Avatar
 
elite*gold: 35
Join Date: Aug 2007
Posts: 460
Received Thanks: 114
PHP Code:
;Globale Variablen definieren
GLOBAL $status False

;dann hotkeys setzen
 HotKeySet
("{F2}","status")
 
HotKeySet("{F3}","beenden")


;Die 
eigentliche Programmschleife
While 1
Zeit
()
Wend


;Die benötigten Funktionen


Func Zeit
()
    If 
$status == True then
        ToolTip
("Stunde: " & @HOUR " Minute: " & @MIN " Sekunde: " & @SEC ,0,0)
        
Sleep(500)
    Else
        
ToolTip("Stopped" ,0,0)
        
Sleep(500)
    EndIf
EndFunc

Func status
()
    If 
$status==False Then
        $status
=True
    
Else
        
$status=False
    
EndIf
EndFunc

Func beenden
()
    Exit
EndFunc 
Das kleine Demo Programm sollte dir es glaube ich ganz gut veranschaulichen. (;


EDIT: Mir fällt geraude auf, das deine While-Schleifen alles Endlosschleifen sind.
mit dem Befehl "ExitLoop" kannst du ganz einfach die Schleife (zB wen netwas bestimmtes getan wurde) verlassen

zB
PHP Code:
While 1
ToolTip
("Status ist False" ,0,0)
If 
$status==True then Exitloop
WEnd 
Gotoxy is offline  
Thanks
1 User
Old 02/18/2013, 22:27   #5
 
golle12's Avatar
 
elite*gold: 29
Join Date: Aug 2011
Posts: 640
Received Thanks: 493
Danke für deine Antworten und die schnellen Hilfen
PHP Code:
Global $Paused
Global $status False
$passwort 
InputBox ("Passwort Manager","Bitte geben sie das Passwort ein!","","*")
 If 
$passwort "" Then
    MsgBox
(64"Passwort Manager""Das Passwort wurde richtig eingegeben!",1)
Else
 
MsgBox(16"ERROR 405""Zugriff Verweigert! " &@CRLF" Bitte geben sie das Passwort richtig ein!",2)
Exit
 EndIf
#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_Res_requestedExecutionLevel=asInvoker
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#NoTrayIcon
#include <EditConstants.au3>
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
Opt("GUIOnEventMode"1)
$Form1 GUICreate("League of Legends afk Bot made by "418227196126)
$Group1 GUICtrlCreateGroup("LOL afk Bot"00417225)
$Button1 GUICtrlCreateButton("Start"81764341)
$Button2 GUICtrlCreateButton("Exit"561767541)
$Label1 GUICtrlCreateLabel("Bot made by "14419226624)
GUICtrlSetFont(-1128002"MS Sans Serif")
$Label2 GUICtrlCreateLabel("F2: Start"16166120)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Label3 GUICtrlCreateLabel("F3: Login"16406720)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Pic1 GUICtrlCreatePic("C:\Users\Privat\Desktop\Afk Bot\Pentakill.jpg"968321161)
$Button3 GUICtrlCreateButton("Go LOL"81367333)
$Label4 GUICtrlCreateLabel("F5: Stop"16886120)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Label5 GUICtrlCreateLabel("F7: Pause"161127320)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Label6 GUICtrlCreateLabel("F4: Spiel"16646520)
GUICtrlSetFont(-1108000"MS Sans Serif")
GUICtrlCreateGroup("", -99, -9911)
GUISetState(@SW_SHOW)
GUISetOnEvent($GUI_EVENT_CLOSE"_Exit")
GUICtrlSetOnEvent($Button1"_Start")
GUICtrlSetOnEvent($Button2"_Exit")
GUICtrlSetOnEvent($Button3"_Login")

While 
1
    $nMsg 
GUIGetMsg()
    Switch 
$nMsg
        
Case $GUI_EVENT_CLOSE
            
Exit
        Case 
$Button1
            _Start
()
        Case 
$Button2
            _Exit
()
        Case 
$Button3
            _Login
()
    EndSwitch
    
HotKeySet("{F2}","Start")
    
HotKeySet("{F3}","Login")
    
HotKeySet("{F4}","Start_Spiel")
    
HotKeySet("{F5}","Stop")
    
HotKeySet("{F7}""TogglePause")
WEnd

While 1
Start
()
_Start()
WEnd


Func Login
()
$acountname ""
$passwort ""
 
If Run("C:\Riot Games\League of Legends\lol.launcher.exe"Then
MsgBox
(64,"League of Legends Launcher!","Launcher wird gestartet " &@CRLF" und wirst eingeloggt!",12)
 Else
MsgBox(16,"ERROR 426!","League of Legends nicht insatlliert " &@CRLF" bitte installieren sie LOL!",6)
Exit
EndIf
Sleep(1500)
MouseClick("left"9426301)
Sleep(13000)
MouseClick("left"3133022)
Sleep(1000)
Send("{BACKSPACE 13}")
Sleep(1000)
Send ($acountname)
MouseClick("left",286,358,1)
Sleep(1500)
Send($passwort)
Sleep(2500)
MouseClick("left",406,428,1)
Sleep(6000)
MsgBox(64,"Erfolgreich","Login erfolgreich",2)
EndFunc

Func _Login
()
$acountname ""
$passwort ""
 
If Run("C:\Riot Games\League of Legends\lol.launcher.exe"Then
MsgBox
(64,"League of Legends Launcher!","Launcher wird gestartet " &@CRLF" und wirst eingeloggt!",12)
 Else
MsgBox(16,"ERROR 426!","League of Legends nicht insatlliert " &@CRLF" bitte installieren sie LOL!",6)
Exit
EndIf
Sleep(1500)
MouseClick("left"9426301)
Sleep(13000)
MouseClick("left"3133022)
Sleep(1000)
Send("{BACKSPACE 13}")
Sleep(1000)
Send ($acountname)
MouseClick("left",286,358,1)
Sleep(1500)
Send($passwort)
Sleep(2500)
MouseClick("left",406,428,1)
Sleep(6000)
MsgBox(64,"Erfolgreich","Login erfolgreich",2)
EndFunc

Func Start
()
    If 
$status == False Then
        $status 
True
Sleep
(10)
Sleep(3000)
MouseClick("right",1189,695,1)
Sleep(9000)
MouseClick("right",940,427,1)
Sleep(9000)
MouseClick("right",717,429,1)
Sleep(8000)
MouseClick("right",702,421,1)
Sleep(8000)
MouseClick("right",703,429,1)
Sleep(8000)
MouseClick("right",721,427,1)
Sleep(6000)
MouseClick("right",696,437,1)
Sleep(7000)
MouseClick("right",674,434,1)
Sleep(10000)
Send("b")
Sleep(600)
Else
    
ToolTip("Bot wurde gestoppt" ,0,0)
    
Sleep(500)
    EndIf
EndFunc

Func _Start
()
    If 
$status== False Then
        $status 
True
Sleep
(3000)
MouseClick("right",1189,695,1)
Sleep(9000)
MouseClick("right",940,427,1)
Sleep(9000)
MouseClick("right",717,429,1)
Sleep(8000)
MouseClick("right",702,421,1)
Sleep(8000)
MouseClick("right",703,429,1)
Sleep(8000)
MouseClick("right",721,427,1)
Sleep(6000)
MouseClick("right",696,437,1)
Sleep(7000)
MouseClick("right",674,434,1)
Sleep(10000)
Send("b")
Sleep(600)
Else
    
ToolTip("Bot wurde gestoppt" ,0,0)
    
Sleep(500)
    EndIf
EndFunc

Func Start_Spiel
()
MsgBox(64,"Bot Game","/Bot Game\/Kluft der Beschwörer\/Anfänger\",5)
Sleep(100)
MouseClick("
left",685,45,1)
Sleep(1999)
MouseClick("
left",380,173,1)
Sleep(100)
MouseClick("
left",587,145,1)
Sleep(100)
MouseClick("
left",759,152,1)
Sleep(100)
MouseClick("
left",956,146,1)
Sleep(100)
MouseClick("
left",796,682,1)
Sleep(1000)
While 1
$Annehmen = PixelSearch(541,417,635,442,0x224C7F,0) ;richtig
If IsArray(
$Annehmen) Then
MouseClick("
left",585,431,1)
EndIf
Sleep(500)
WEnd
Sleep(4000)
$Teemo = PixelSearch(541,417,635,442,0x224C7F,0) ;falsch musst noch heraus suchen
$Darius = PixelSearch(541,417,635,442,0x224C7F,0) ;falsch musst noch heraus suchen
$Akali = PixelSearch(541,417,635,442,0x224C7F,0) ;falsch musst noch heraus suchen
$Morgana = PixelSearch(541,417,635,442,0x224C7F,0) ;falsch musst noch heraus suchen
$Shaco = PixelSearch(541,417,635,442,0x224C7F,0) ;falsch musst noch heraus suchen
$Garen = PixelSearch(541,417,635,442,0x224C7F,0) ;falsch musst noch heraus suchen
$Vaigar = PixelSearch(541,417,635,442,0x224C7F,0) ;falsch musst noch heraus suchen
$Teemo= InputBox("Champ Auswahl","Bitte wähle dir einen " &@CRLF& " von den Champs aus:" &@CRLF& " -Teemo" &@CRLF& " -Darius" &@CRLF& " -Akali" &@CRLF& " -Morgana" &@CRLF& " -Shaco" &@CRLF& " -Garen" &@CRLF& " -Vaigar")
$Ausgabe = $Teemo
If IsArray(
$Teemo) Then
MouseMove(
$Teemo[0],$Teemo[1],0)
MouseClick("
left")
Sleep(500)
EndIf
EndFunc

Func _Exit()
Exit
EndFunc

Func Stop()
    While 1
If 
$status = False Then Exitloop
WEnd
EndFunc

Func TogglePause()
    
$Paused = NOT $Paused
    While 
$Paused
        sleep(500)
        ToolTip("
Bot wird pausiert!",0,0)
    WEnd
    ToolTip("
Pause beendet!",0,0)
    Sleep(1500)
    ToolTip("")
EndFunc 
################################################## ################################################## ####
Hier ist das Script ein wenig verbessert mit der Stop() funktion aber leider wenn ich bei der gui auf start klicke und mit meiner stop funtion die while schleife beende kann ich das fenster nicht mehr schließen und muss es über den tasmanager terminieren, aber mit den hotkeys funktionierts da her meine Frage wieso (trotz Gui event mode) kann ich nicht mehr irgend etwas auf dem Fenster anklicken(doch schon es reagiert blos nichts ) ich hoffe du kannst mir bitte wieder helfen.
golle12 is offline  
Old 02/19/2013, 10:29   #6
 
Gotoxy's Avatar
 
elite*gold: 35
Join Date: Aug 2007
Posts: 460
Received Thanks: 114
Ich kann dein Programm leider nicht testen,da ich anscheind andere ganz andere Bildschirmauflösung habe als du

Aber ein paar Verbesserung gibs noch.
Die HotKeySet sachen musst du nicht in eine Schleife legen, egal wo sie stehen, sie sind scriptübergreifend, dH kannst du sie auch gleich zum Anfang des Sripts stellen.

Ich kann dir nur nahelegen von den Klicks auf Koordinanten wegzugehen und die imgsearch au3 zu verwenden(google..)
damit sucht su einfach ein bild auf deinem Monitor(zB Temmo ava in der champ auswahl) und dann hast die die koords=>dann klick auf die koords.

Bedeutend sicherer ; )
Gotoxy is offline  
Thanks
1 User
Old 02/19/2013, 15:35   #7
 
golle12's Avatar
 
elite*gold: 29
Join Date: Aug 2011
Posts: 640
Received Thanks: 493
Ok Danke

PHP Code:
Global $Paused
Global $status False
$passwort 
InputBox ("Passwort Manager","Bitte geben sie das Passwort ein!","","*")
 If 
$passwort "" Then
    MsgBox
(64"Passwort Manager""Das Passwort wurde richtig eingegeben!",1)
Else
 
MsgBox(16"ERROR 405""Zugriff Verweigert! " &@CRLF" Bitte geben sie das Passwort richtig ein!",2)
Exit
 EndIf
#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_Res_requestedExecutionLevel=asInvoker
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#include <EditConstants.au3>
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
Opt("GUIOnEventMode"1)
$Form1 GUICreate("League of Legends afk Bot made by "418227196126)
$Group1 GUICtrlCreateGroup("LOL afk Bot"00417225)
$Button1 GUICtrlCreateButton("Start"81764341)
$Button2 GUICtrlCreateButton("Exit"561767541)
$Label1 GUICtrlCreateLabel("Bot made by "14419226624)
GUICtrlSetFont(-1128002"MS Sans Serif")
$Label2 GUICtrlCreateLabel("F2: Start"16166120)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Label3 GUICtrlCreateLabel("F3: Login"16406720)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Pic1 GUICtrlCreatePic("C:\Users\Privat\Desktop\Afk Bot\Pentakill.jpg"968321161)
$Button3 GUICtrlCreateButton("Go LOL"81367333)
$Label4 GUICtrlCreateLabel("F5: Stop"16886120)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Label5 GUICtrlCreateLabel("F7: Pause"161127320)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Label6 GUICtrlCreateLabel("F4: Spiel"16646520)
GUICtrlSetFont(-1108000"MS Sans Serif")
GUICtrlCreateGroup("", -99, -9911)
GUISetState(@SW_SHOW)
GUISetOnEvent($GUI_EVENT_CLOSE"_Exit")
GUICtrlSetOnEvent($Button1"_Start")
GUICtrlSetOnEvent($Button2"_Exit")
GUICtrlSetOnEvent($Button3"_Login")
HotKeySet("{F2}","Start")
    
HotKeySet("{F3}","Login")
    
HotKeySet("{F4}","Start_Spiel")
    
HotKeySet("{F5}","Stop")
    
HotKeySet("{F7}""TogglePause")
While 
1
    $nMsg 
GUIGetMsg()
    Switch 
$nMsg
        
Case $GUI_EVENT_CLOSE
            
Exit
        Case 
$Button1
            _Start
()
        Case 
$Button2
            _Exit
()
        Case 
$Button3
            _Login
()
    EndSwitch
WEnd

While 1
    Start
()
WEnd

While 2
    _Start
()
WEnd

#include <ImageSearch.au3>
$x1=0
$y1
=0
$x2
=0
$y2
=0
$x3
=0
$y3
=0
$x4
=0
$y4
=0
$x5
=0
$y5
=0
$x6
=0
$y6
=0
$x7
=0
$y7
=0
$x8
=0
$y8
=0


Func Login
()
$acountname ""
$passwort ""
 
If Run("C:\Riot Games\League of Legends\lol.launcher.exe"Then
MsgBox
(64,"League of Legends Launcher!","Launcher wird gestartet " &@CRLF" und wirst eingeloggt!",5)
 Else
MsgBox(16,"ERROR 426!","League of Legends nicht insatlliert " &@CRLF" bitte installieren sie LOL!",5)
Exit
EndIf
While 
1
$result 
=_ImageSearch("Start Button.jpg",1,$x1,$y1,0)
If 
$result 1 Then
MouseClick
("left"$x1$y1)
Sleep(560)
EndIf
If 
$status False Then ExitLoop
WEnd
Sleep
(600)
While 
2
$wait 
"LolClient.exe"
ProcessWait ($wait)
Sleep(12500)
$result9 =_ImageSearch("Einloggen.jpg",1,$x2,$y2,0)
If 
$result9 1 Then
MouseClick
("left",$x2,$y2)
Sleep(560)
EndIf
If 
$status False Then ExitLoop
WEnd
Sleep
(1000)
Send("{BACKSPACE 13}")
Sleep(1000)
Send ($acountname)
Sleep(1500)
$result1 _ImageSearch("Einloggen Passwort.jpg",1,$x3,$y3,0)
If 
$result1 1 Then
    MouseClick
("left",$x3,$y3)
Send($passwort)
Sleep(2500)
EndIf
While 
3
$result2 
_ImageSearch("Einloggen Einloggen.jpg",1,$x4,$y4,0)
If 
$result2 1 Then
MouseClick
("left",$x4,$y4)
Sleep(560)
EndIf
If 
$status False Then ExitLoop
WEnd
Sleep
(6000)
MsgBox(64,"Erfolgreich","Login erfolgreich",2)
EndFunc

Func _Login
()
$acountname ""
$passwort ""
 
If Run("C:\Riot Games\League of Legends\lol.launcher.exe"Then
MsgBox
(64,"League of Legends Launcher!","Launcher wird gestartet " &@CRLF" und wirst eingeloggt!",5)
 Else
MsgBox(16,"ERROR 426!","League of Legends nicht insatlliert " &@CRLF" bitte installieren sie LOL!",5)
Exit
EndIf
While 
1
$result3 
=_ImageSearch("Start Button.jpg",1,$x5,$y5,0)
If 
$result3 1 Then
MouseClick
("left"$x5$y5)
Sleep(560)
EndIf
If 
$status False Then ExitLoop
WEnd
Sleep
(600)
While 
2
$wait 
"LolClient.exe"
ProcessWait ($wait)
Sleep(12500)
$result4 =_ImageSearch("Einloggen.jpg",1,$x6,$y6,0)
If 
$result4 1 Then
MouseClick
("left",$x6,$y6)
Sleep(560)
EndIf
If 
$status False Then ExitLoop
WEnd
Sleep
(1000)
Send("{BACKSPACE 13}")
Sleep(1000)
Send ($acountname)
Sleep(1500)
$result5 _ImageSearch("Einloggen Passwort.jpg",1,$x7,$y7,0)
If 
$result5 1 Then
    MouseClick
("left",$x7,$y7)
Send($passwort)
Sleep(2500)
While 
3
$result6 
_ImageSearch("Einloggen Einloggen.jpg",1,$x8,$y8,0)
If 
$result6 1 Then
MouseClick
("left",$x8,$y8)
Sleep(560)
EndIf
If 
$status False Then ExitLoop
WEnd
Sleep
(6000)
MsgBox(64,"Erfolgreich","Login erfolgreich",2)
EndIf
EndFunc

Func Start
()
    If 
$status False Then
        $status 
True
Sleep
(3000)
MouseClick("right",1189,695,1)
Sleep(9000)
MouseClick("right",1228,708,1)
Sleep(9000)
MouseClick("right",1240,747,1)
Sleep(8000)
MouseClick("right",1203,737,1)
Sleep(8000)
MouseClick("right",1208,665,1)
Sleep(8000)
MouseClick("right",1255,715,1)
Sleep(6000)
MouseClick("right",1254,739,1)
Sleep(7000)
MouseClick("right",1281,738,1)
Sleep(10000)
Send("b")
Sleep(9600)
Else
ToolTip("Bot wurde gestoppt" ,0,0)
Sleep(500)
EndIf
EndFunc

Func _Start
()
    If 
$status False Then
        $status 
True
Sleep
(3000)
MouseClick("right",1189,695,1)
Sleep(9000)
MouseClick("right",1228,708,1)
Sleep(9000)
MouseClick("right",1240,747,1)
Sleep(8000)
MouseClick("right",1203,737,1)
Sleep(8000)
MouseClick("right",1208,665,1)
Sleep(8000)
MouseClick("right",1255,715,1)
Sleep(6000)
MouseClick("right",1254,739,1)
Sleep(7000)
MouseClick("right",1281,738,1)
Sleep(10000)
Send("b")
Sleep(9600)
Else
ToolTip("Bot wurde gestoppt" ,0,0)
Sleep(500)
EndIf
EndFunc

Func Start_Spiel
()
MsgBox(64,"Bot Game","/Bot Game\/Kluft der Beschwörer\/Anfänger\",5)
Sleep(100)
MouseClick("
left",685,45,1)
Sleep(1999)
MouseClick("
left",380,173,1)
Sleep(100)
MouseClick("
left",587,145,1)
Sleep(100)
MouseClick("
left",759,152,1)
Sleep(100)
MouseClick("
left",956,146,1)
Sleep(100)
MouseClick("
left",796,682,1)
Sleep(1000)
While 1
$resul7 = _ImageSearch("Einloggen Einloggen.jpg",1,$x1,$y1,0)
If 
$resul7 = 1 Then
    Sleep(500)
MouseClick("
left",1,$x1,$y1,1)
EndIf
Sleep(500)
WEnd
Sleep(4000)
$Leblanc = _ImageSearch("Leblanc.jpg",1,$x1,$y1,0)
$Katarina =_ImageSearch("Katarina.jpg",1,$x1,$y1,0)
$Teemo =_ImageSearch("Teemo.jpg",1,$x1,$y1,0)
$Darius =_ImageSearch("Darius.jpg",1,$x1,$y1,0)
$Akali = _ImageSearch("Akali.jpg",1,$x1,$y1,0)
$Morgana =_ImageSearch("Morgana.jpg",1,$x1,$y1,0)
$Shaco =_ImageSearch("Shaco.jpg",1,$x1,$y1,0)
$Garen = _ImageSearch("Garen.jpg",1,$x1,$y1,0)
$Vaigar =_ImageSearch("Vaigar.jpg",1,$x1,$y1,0)
$Teemo= InputBox("Champ Auswahl","Bitte wähle dir einen " &@CRLF& " von den Champs aus:" &@CRLF& " -Teemo" &@CRLF& " -Darius" &@CRLF& " -Akali" &@CRLF& " -Morgana" &@CRLF& " -Shaco" &@CRLF& " -Garen" &@CRLF& " -Vaigar" &@CRLF& " -Katarina" &@CRLF& " -Leblanc")
$Ausgabe = $Teemo
If IsArray(
$Teemo) Then
MouseMove(
$Teemo[0],$Teemo[1],0)
MouseClick("
left")
Sleep(500)
EndIf
EndFunc

Func _Exit()
Exit
EndFunc

Func Stop()
    While 1
If 
$status = False Then ExitLoop
ToolTip("
Afk Bot wird beendet",0,0)
Sleep(600)
ToolTip("")
WEnd
EndFunc

Func TogglePause()
    
$Paused = NOT $Paused
    While 
$Paused
        sleep(500)
        ToolTip("
Bot wird pausiert!",0,0)
    WEnd
    ToolTip("
Pause beendet!",0,0)
    Sleep(1500)
    ToolTip("")
EndFunc 
Folgende Problematik ist mir auch noch aufgefallen und zwar wenn ich den afk bot starte fängt er an 8-mal herum zu klicken bis er B Sendet (Send("B"))
dann passiert gar nichts mehr drücke ich dann noch eimal auf Start wird mir durch den Tooltip gezeigt dass der Bot gestoppt wurde nur weiß ich nicht wieso er nicht weiter in der while schleife herum irrt deshalb meine Frage was ich falsch gemacht habe ;;; und dann wollte ich auch noch fragen bei meiner Stop funktion habe ich einen Tooltip mit eingebaut um zu sehen ob der Bot dann auch die While Schleife beendet aber dann bleibt die Stop funktion in einer While Schleife und dann kann ich keine Funktion mehr starten. Zu dem habe ich wie du gesagt hast mal es mit imagesearch probiert an sich ist es nicht schwer das programm startet auch aber statt die Sachen auszuführen die ich geschrieben habe schließt sich das Progamm,ich bin wirklich am verzweifeln. Ich hoffe dass du mir Bitte bei de Problemen Helfen kannst. Danke
golle12 is offline  
Old 02/22/2013, 11:46   #8
 
Gotoxy's Avatar
 
elite*gold: 35
Join Date: Aug 2007
Posts: 460
Received Thanks: 114
PHP Code:
Global $Paused
Global $status False
$passwort 
InputBox ("Passwort Manager","Bitte geben sie das Passwort ein!","","*")
 If 
$passwort "" Then
    MsgBox
(64"Passwort Manager""Das Passwort wurde richtig eingegeben!",1)
Else
 
MsgBox(16"ERROR 405""Zugriff Verweigert! " &@CRLF" Bitte geben sie das Passwort richtig ein!",2)
Exit
 EndIf
#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_Res_requestedExecutionLevel=asInvoker
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#include <EditConstants.au3>
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
Opt("GUIOnEventMode"1)
$Form1 GUICreate("League of Legends afk Bot made by "418227196126)
$Group1 GUICtrlCreateGroup("LOL afk Bot"00417225)
$Button1 GUICtrlCreateButton("Start"81764341)
$Button2 GUICtrlCreateButton("Exit"561767541)
$Label1 GUICtrlCreateLabel("Bot made by "14419226624)
GUICtrlSetFont(-1128002"MS Sans Serif")
$Label2 GUICtrlCreateLabel("F2: Start"16166120)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Label3 GUICtrlCreateLabel("F3: Login"16406720)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Pic1 GUICtrlCreatePic("C:\Users\Privat\Desktop\Afk Bot\Pentakill.jpg"968321161)
$Button3 GUICtrlCreateButton("Go LOL"81367333)
$Label4 GUICtrlCreateLabel("F5: Stop"16886120)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Label5 GUICtrlCreateLabel("F7: Pause"161127320)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Label6 GUICtrlCreateLabel("F4: Spiel"16646520)
GUICtrlSetFont(-1108000"MS Sans Serif")
GUICtrlCreateGroup("", -99, -9911)
GUISetState(@SW_SHOW)
GUISetOnEvent($GUI_EVENT_CLOSE"_Exit")
GUICtrlSetOnEvent($Button1"_Start")
GUICtrlSetOnEvent($Button2"_Exit")
GUICtrlSetOnEvent($Button3"_Login")
HotKeySet("{F2}","Start")
    
HotKeySet("{F3}","Login")
    
HotKeySet("{F4}","Start_Spiel")
    
HotKeySet("{F5}","Stop")
    
HotKeySet("{F7}""TogglePause")
While 
1
    $nMsg 
GUIGetMsg()
    Switch 
$nMsg
        
Case $GUI_EVENT_CLOSE
            
Exit
        Case 
$Button1
            _Start
()
        Case 
$Button2
            _Exit
()
        Case 
$Button3
            _Login
()
    EndSwitch
WEnd

While 1
    Start
()
WEnd

While ;while warumdas wäre die bedingung und keine funktionsdefinitiondaher reicht wile 1,while schleifen haben keinen namen^^
    
_Start()
WEnd

#include <ImageSearch.au3>
$x1=0
$y1
=0
$x2
=0
$y2
=0
$x3
=0
$y3
=0
$x4
=0
$y4
=0
$x5
=0
$y5
=0
$x6
=0
$y6
=0
$x7
=0
$y7
=0
$x8
=0
$y8
=0


Func Login
()
$acountname ""
$passwort ""
 
If Run("C:\Riot Games\League of Legends\lol.launcher.exe"Then
MsgBox
(64,"League of Legends Launcher!","Launcher wird gestartet " &@CRLF" und wirst eingeloggt!",5)
 Else
MsgBox(16,"ERROR 426!","League of Legends nicht insatlliert " &@CRLF" bitte installieren sie LOL!",5)
Exit
EndIf
While 
1
$result 
=_ImageSearch("Start Button.jpg",1,$x1,$y1,100) ;das ideale bild zu finden ist schwerversuche es mit leichten abweichungen,100 zb
If $result 1 Then
MouseClick
("left"$x1$y1)
Sleep(560)
EndIf
If 
$status False Then ExitLoop
WEnd
Sleep
(600)
While 
2
$wait 
"LolClient.exe"
ProcessWait ($wait)
Sleep(12500)
$result9 =_ImageSearch("Einloggen.jpg",1,$x2,$y2,100) ;same
If $result9 1 Then
MouseClick
("left",$x2,$y2)
Sleep(560)
EndIf
If 
$status False Then ExitLoop
WEnd
Sleep
(1000)
Send("{BACKSPACE 13}")
Sleep(1000)
Send ($acountname)
Sleep(1500)
$result1 _ImageSearch("Einloggen Passwort.jpg",1,$x3,$y3,100) ;same
If $result1 1 Then
    MouseClick
("left",$x3,$y3)
Send($passwort)
Sleep(2500)
EndIf
While 
3
$result2 
_ImageSearch("Einloggen Einloggen.jpg",1,$x4,$y4,100) ;same
If $result2 1 Then
MouseClick
("left",$x4,$y4)
Sleep(560)
EndIf
If 
$status False Then ExitLoop
WEnd
Sleep
(6000)
MsgBox(64,"Erfolgreich","Login erfolgreich",100) ;same
EndFunc

Func _Login
()
$acountname ""
$passwort ""
 
If Run("C:\Riot Games\League of Legends\lol.launcher.exe"Then
MsgBox
(64,"League of Legends Launcher!","Launcher wird gestartet " &@CRLF" und wirst eingeloggt!",5)
 Else
MsgBox(16,"ERROR 426!","League of Legends nicht insatlliert " &@CRLF" bitte installieren sie LOL!",5)
Exit
EndIf
While 
1
$result3 
=_ImageSearch("Start Button.jpg",1,$x5,$y5,100) ;same
If $result3 1 Then
MouseClick
("left"$x5$y5)
Sleep(560)
EndIf
If 
$status False Then ExitLoop
WEnd
Sleep
(600)
While 
2
$wait 
"LolClient.exe"
ProcessWait ($wait)
Sleep(12500)
$result4 =_ImageSearch("Einloggen.jpg",1,$x6,$y6,100) ;same
If $result4 1 Then
MouseClick
("left",$x6,$y6)
Sleep(560)
EndIf
If 
$status False Then ExitLoop
WEnd
Sleep
(1000)
Send("{BACKSPACE 13}")
Sleep(1000)
Send ($acountname)
Sleep(1500)
$result5 _ImageSearch("Einloggen Passwort.jpg",1,$x7,$y7,100) ;same
If $result5 1 Then
    MouseClick
("left",$x7,$y7)
Send($passwort)
Sleep(2500)
While 
3
$result6 
_ImageSearch("Einloggen Einloggen.jpg",1,$x8,$y8,0100) ;same
If $result6 1 Then
MouseClick
("left",$x8,$y8)
Sleep(560)
EndIf
If 
$status False Then ExitLoop
WEnd
Sleep
(6000)
MsgBox(64,"Erfolgreich","Login erfolgreich",2)
EndIf
EndFunc

Func Start
()
    If 
$status False Then
        $status 
True
Sleep
(3000)
MouseClick("right",1189,695,1)
Sleep(9000)
MouseClick("right",1228,708,1)
Sleep(9000)
MouseClick("right",1240,747,1)
Sleep(8000)
MouseClick("right",1203,737,1)
Sleep(8000)
MouseClick("right",1208,665,1)
Sleep(8000)
MouseClick("right",1255,715,1)
Sleep(6000)
MouseClick("right",1254,739,1)
Sleep(7000)
MouseClick("right",1281,738,1)
Sleep(10000)
Send("b")
Sleep(9600)
Else
ToolTip("Bot wurde gestoppt" ,0,0)
Sleep(500)
EndIf
EndFunc

Func _Start
()
    If 
$status False Then
        $status 
True
Sleep
(3000)
MouseClick("right",1189,695,1)
Sleep(9000)
MouseClick("right",1228,708,1)
Sleep(9000)
MouseClick("right",1240,747,1)
Sleep(8000)
MouseClick("right",1203,737,1)
Sleep(8000)
MouseClick("right",1208,665,1)
Sleep(8000)
MouseClick("right",1255,715,1)
Sleep(6000)
MouseClick("right",1254,739,1)
Sleep(7000)
MouseClick("right",1281,738,1)
Sleep(10000)
Send("b")
Sleep(9600)
Else
ToolTip("Bot wurde gestoppt" ,0,0)
Sleep(500)
EndIf
EndFunc

Func Start_Spiel
()
MsgBox(64,"Bot Game","/Bot Game\/Kluft der Beschwörer\/Anfänger\",5)
Sleep(100)
MouseClick("
left",685,45,1)
Sleep(1999)
MouseClick("
left",380,173,1)
Sleep(100)
MouseClick("
left",587,145,1)
Sleep(100)
MouseClick("
left",759,152,1)
Sleep(100)
MouseClick("
left",956,146,1)
Sleep(100)
MouseClick("
left",796,682,1)
Sleep(1000)
While 1
$resul7 = _ImageSearch("Einloggen Einloggen.jpg",1,$x1,$y1,0)
If 
$resul7 = 1 Then
    Sleep(500)
MouseClick("
left",1,$x1,$y1,1)
EndIf
Sleep(500)
WEnd
Sleep(4000);hier suchst du für die champs die posis, schreibst sie aber ALLE i die selbe variabl => nur die lezte posi wird gespeichert,dH teemo. alternativ leblanx_x,leblanc_y etc verwenden
$Leblanc = _ImageSearch("Leblanc.jpg",1,$x1,$y1,0)
$Katarina =_ImageSearch("Katarina.jpg",1,$x1,$y1,0)
$Teemo =_ImageSearch("Teemo.jpg",1,$x1,$y1,0)
$Darius =_ImageSearch("Darius.jpg",1,$x1,$y1,0)
$Akali = _ImageSearch("Akali.jpg",1,$x1,$y1,0)
$Morgana =_ImageSearch("Morgana.jpg",1,$x1,$y1,0)
$Shaco =_ImageSearch("Shaco.jpg",1,$x1,$y1,0)
$Garen = _ImageSearch("Garen.jpg",1,$x1,$y1,0)
$Vaigar =_ImageSearch("Vaigar.jpg",1,$x1,$y1,0)
$Teemo= InputBox("Champ Auswahl","Bitte wähle dir einen " &@CRLF& " von den Champs aus:" &@CRLF& " -Teemo" &@CRLF& " -Darius" &@CRLF& " -Akali" &@CRLF& " -Morgana" &@CRLF& " -Shaco" &@CRLF& " -Garen" &@CRLF& " -Vaigar" &@CRLF& " -Katarina" &@CRLF& " -Leblanc")
$Ausgabe = $Teemo
If IsArray(
$Teemo) Then
MouseMove(
$Teemo[0],$Teemo[1],0);same kann heir alles nicht gehe nda falsche posis
MouseClick("
left");click WOHIN?
Sleep(500)
EndIf
EndFunc

Func _Exit()
Exit
EndFunc

Func Stop()
    While 1
If 
$status = False Then ExitLoop ;hier wird die schleife verlassen
ToolTip("
Afk Bot wird beendet",0,0)
Sleep(600)
ToolTip("")
WEnd
EndFunc

Func TogglePause()
    
$Paused = NOT $Paused
    While 
$Paused
        sleep(500)
        ToolTip("
Bot wird pausiert!",0,0)
    WEnd
    ToolTip("
Pause beendet!",0,0)
    Sleep(1500)
    ToolTip("")
EndFunc 
Ich kann dir nur raten,diesen Bot abzuhacken und mit einem richtigen Plan nochmal neu anzufangen^^.

hier ein paar starthilfen was du brauchst:

- Acc+PW aus einer Datei lesen
- prüfen ob lvl X bereits erreicht wurde
- spiel starten
- nächstes spiel

das machst du als einfache funktionen und tada ist es fertig^^
Gotoxy is offline  
Thanks
1 User
Old 02/22/2013, 16:44   #9
 
golle12's Avatar
 
elite*gold: 29
Join Date: Aug 2011
Posts: 640
Received Thanks: 493

PHP Code:
Global $Paused
Global $x1$y1 $result1$result2$result3 $result4$result5$result6$result7$result8$result9$result10$result11$result12$result13$result14$result15$result16$StartB$Einloggen ,$EinloggenP$EinloggenE
Global $Spielen$Bot_Game$Klassisch, $5vs5_K_d_B$Anfaenger$Start_Bot_Game$Annehmen$Bestaetigen
Global $status False
$passwort 
InputBox ("Passwort Manager","Bitte geben sie das Passwort ein!","","*")
 If 
$passwort "" Then
    MsgBox
(64"Passwort Manager""Das Passwort wurde richtig eingegeben!",1)
Else
 
MsgBox(16"ERROR 405""Zugriff Verweigert! " &@CRLF" Bitte geben sie das Passwort richtig ein!",2)
 Exit
 EndIf
#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_UseX64=n
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#include <EditConstants.au3>
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#include <ImageSearch.au3>
#NoTrayIcon
Opt("GUIOnEventMode"1)
$Form1 GUICreate("League of Legends afk Bot made by "418227196126)
$Group1 GUICtrlCreateGroup("LOL afk Bot"00417225)
$Button1 GUICtrlCreateButton("Start"81764341)
$Button2 GUICtrlCreateButton("Exit"561767541)
$Label1 GUICtrlCreateLabel("Bot made by "14419226624)
GUICtrlSetFont(-1128002"MS Sans Serif")
$Label2 GUICtrlCreateLabel("F2: Start"16166120)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Label3 GUICtrlCreateLabel("F3: Login"16406720)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Pic1 GUICtrlCreatePic("G:\LOL Afk Bot\League of Legends Afk Bot\Pentakill.jpg"968321161)
$Button3 GUICtrlCreateButton("Go LOL"81367333)
$Label4 GUICtrlCreateLabel("F5: Stop"16886120)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Label5 GUICtrlCreateLabel("F7: Pause"161127320)
GUICtrlSetFont(-1108000"MS Sans Serif")
$Label6 GUICtrlCreateLabel("F4: Spiel"16646520)
GUICtrlSetFont(-1108000"MS Sans Serif")
GUICtrlCreateGroup("", -99, -9911)
GUISetState(@SW_SHOW)
FileInstall("Pentakill.jpg",@TempDir "Pentakill.jpg")
GUISetOnEvent($GUI_EVENT_CLOSE"_Exit")
GUICtrlSetOnEvent($Button1"_Start")
GUICtrlSetOnEvent($Button2"_Exit")
GUICtrlSetOnEvent($Button3"_Login")
    
HotKeySet("{F2}","Start")
    
HotKeySet("{F3}","Login")
    
HotKeySet("{F4}","Start_Spiel")
    
HotKeySet("{F5}","Stop")
    
HotKeySet("{F7}""TogglePause")
While 
1
    $nMsg 
GUIGetMsg()
    Switch 
$nMsg
        
Case $GUI_EVENT_CLOSE
            
Exit
        Case 
$Button1
            _Start
()
        Case 
$Button2
            _Exit
()
        Case 
$Button3
            _Login
()
    EndSwitch
WEnd

$StartB 
= @ScriptDir "\Start Button.png"
$Einloggen = @ScriptDir "\Einloggen.png"
$EinloggenP = @ScriptDir "\Einloggen Passwort.png"
$EinloggenE = @ScriptDir "\Einloggen Einloggen.png"

$x1=0
$y1
=0

Func Login
()
    If 
Not FileExists("Accountname.ini"Then
        IniWrite
("Accountname.ini","Accountnamen Eingabe","Benutzername",InputBox("Accountname Eingeben","Bitte gib deinen Benutzernamen ein!"))
    EndIf
If 
Not FileExists("Passwort.ini"Then
    IniWrite
("Passwort.ini","Passwort Eingabe","Passwort",InputBox("Passwort Eingeben","Bitte gib dein Passwort ein!","","*"))
EndIf
$accountname IniRead("Accountname.ini","Accountnamen Eingabe","Benutzername","Gefunden")
$passwort IniRead("Passwort.ini","Passwort Eingabe","Passwort","Gefunden")
 If 
Run("C:\Riot Games\League of Legends\lol.launcher.exe"Then
MsgBox
(64,"League of Legends Launcher!","Launcher wird gestartet " &@CRLF" und wirst eingeloggt!",5)
 Else
MsgBox(16,"ERROR 426!","League of Legends ist nicht insatlliert! " &@CRLF" Bitte installieren sie League of Legends um diesen Bot nutzten zu können!",5)
Exit
EndIf
While 
1
$result1 
_ImageSearch($StartB,1,$x1,$y1,100)
If 
$result1=1 Then
MouseClick
("left"$x1$y1)
Sleep(560)
EndIf
If 
$status == False Then ExitLoop
WEnd
Sleep
(600)
While 
2
$wait 
"LolClient.exe"
ProcessWait ($wait)
Sleep(12500)
$result2 _ImageSearch($Einloggen,1,$x1,$y1,100)
If 
$result2=1 Then
MouseClick
("left",$x1,$y1)
Sleep(560)
EndIf
If 
$status == False Then ExitLoop
WEnd
Sleep
(1000)
Send("{BACKSPACE 13}")
Sleep(1000)
Send ($accountname)
Sleep(1500)
While 
3
$result3 
_ImageSearch($EinloggenP,1,$x1,$y1,100)
If 
$result3=1 Then
    MouseClick
("left",$x1,$y1)
Send($passwort)
Sleep(2500)
EndIf
IF 
$status == False Then ExitLoop
WEnd
While 4
$result4 
_ImageSearch($EinloggenE,1,$x1,$y1,100)
If 
$result4=1 Then
MouseClick
("left",$x1,$y1)
Sleep(560)
EndIf
If 
$status == False Then ExitLoop
WEnd
Sleep
(6000)
MsgBox(64,"Erfolgreich","Login erfolgreich",100)
EndFunc

Func _Login
()
If 
Not FileExists("Accountname.ini"Then
        IniWrite
("Accountname.ini","Accountnamen Eingabe","Benutzername",InputBox("Accountname Eingeben","Bitte gib deinen Benutzernamen ein!"))
    EndIf
If 
Not FileExists("Passwort.ini"Then
    IniWrite
("Passwort.ini","Passwort Eingabe","Passwort",InputBox("Passwort Eingeben","Bitte gib dein Passwort ein!","","*"))
EndIf
$accountname IniRead("Accountname.ini","Accountnamen Eingabe","Benutzername","Gefunden")
$passwort IniRead("Passwort.ini","Passwort Eingabe","Passwort","Gefunden")
 If 
Run("C:\Riot Games\League of Legends\lol.launcher.exe"Then
MsgBox
(64,"League of Legends Launcher!","Launcher wird gestartet " &@CRLF" und wirst eingeloggt!",5)
 Else
MsgBox(16,"ERROR 426!","League of Legends ist nicht insatlliert! " &@CRLF" Bitte installieren sie League of Legends!",5)
Exit
EndIf
While 
1
$result5 
_ImageSearch($StartB,1,$x1,$y1,100)
If 
$result5 1 Then
MouseClick
("left"$x1$y1)
Sleep(560)
EndIf
If 
$status == False Then ExitLoop
WEnd
Sleep
(600)
While 
2
$wait 
"LolClient.exe"
ProcessWait ($wait)
Sleep(12500)
$result6 _ImageSearch($Einloggen,1,$x1,$y1,100)
If 
$result6 1 Then
MouseClick
("left",$x1,$y1)
Sleep(560)
EndIf
If 
$status == False Then ExitLoop
WEnd
Sleep
(1000)
Send("{BACKSPACE 13}")
Sleep(1000)
Send ($accountname)
Sleep(1500)
While 
3
$result7 
_ImageSearch($EinloggenP,1,$x1,$y1,100)
If 
$result7 1 Then
    MouseClick
("left",$x1,$y1)
Send($passwort)
Sleep(2500)
EndIf
If 
$status == False Then ExitLoop
WEnd
While 4
$result8 
_ImageSearch($EinloggenE,1,$x1,$y1,100)
If 
$result8 1 Then
MouseClick
("left",$x1,$y1)
Sleep(560)
EndIf
If 
$status == False Then ExitLoop
WEnd
Sleep
(6000)
MsgBox(64,"Erfolgreich","Login erfolgreich",2)
EndFunc

Func Start
()
    If 
$status == False Then
        $status 
True
    
While 1
Sleep
(3000)
MouseClick("right",1189,695,1)
Sleep(9000)
MouseClick("right",1228,708,1)
Sleep(9000)
MouseClick("right",1240,747,1)
Sleep(8000)
MouseClick("right",1203,737,1)
Sleep(8000)
MouseClick("right",1208,665,1)
Sleep(8000)
MouseClick("right",1255,715,1)
Sleep(6000)
MouseClick("right",1254,739,1)
Sleep(7000)
MouseClick("right",1281,738,1)
Sleep(10000)
Send("b")
Sleep(9600)
WEnd
EndIf
EndFunc

Func _Start
()
    If 
$status == False Then
        $status 
True
    
While 1
Sleep
(3000)
MouseClick("right",1189,695,1)
Sleep(9000)
MouseClick("right",1228,708,1)
Sleep(9000)
MouseClick("right",1240,747,1)
Sleep(8000)
MouseClick("right",1203,737,1)
Sleep(8000)
MouseClick("right",1208,665,1)
Sleep(8000)
MouseClick("right",1255,715,1)
Sleep(6000)
MouseClick("right",1254,739,1)
Sleep(7000)
MouseClick("right",1281,738,1)
Sleep(10000)
Send("b")
Sleep(9600)
WEnd
EndIf
EndFunc

$Spielen 
= @ScriptDir "\Spielen.png"
$Bot_Game = @ScriptDir "\Bot Game.png"
$Klassisch = @ScriptDir "\Klassisch.png"
$5vs5_K_d_B = @ScriptDir "\5vs5 Kluft der Beschwörer.png"
$Anfaenger = @ScriptDir "\Anfänger.png"
$Start_Bot_Game = @ScriptDir "\Start Bot Game.png"
$Annehmen = @ScriptDir "\Annehmen.png"
$Bestaetigen = @ScriptDir "\Bestätigen Champ.png"

Func Start_Spiel()
MsgBox(64,"Bot Game","/Bot Game\/Kluft der Beschwörer\/Anfänger\",5)
Sleep(500)
While 1
    
$result9 = _ImageSearch($Spielen,1,$x1,$y1,100)
    If 
$result9 = 1 Then
        Sleep(500)
        MouseClick("
left",$x1,$y1,1)
    EndIf
    If 
$status == False Then ExitLoop
WEnd
Sleep(500)
While 2
$result11 = _ImageSearch($Bot_Game,1,$x1,$y1,100)
If 
$result11 = 1 Then
MouseClick("
left",$x1,$y1,1)
Endif
If 
$status == False Then ExitLoop
WEnd
Sleep(1999)
While 3
$result12 = _ImageSearch($Klassisch,1,$x1,$y1,100)
If 
$result12 = 1 Then
MouseClick("
left",$x1,$y1,1)
Sleep(500)
EndIf
If 
$status == False Then ExitLoop
Wend
While 4
    
$result13 = _ImageSearch($5vs5_K_d_B,1,$x1,$y1,100)
If    
$result13 = 1 Then
MouseClick("
left",$x1,$y1,1)
Sleep(500)
EndIf
If 
$status == False Then ExitLoop
WEnd
While 5
    
$result14 = _ImageSearch($Anfaenger,1,$x1,$y1,100)
    If 
$result14 = 1 Then
MouseClick("
left",$x1,$y1,1)
Sleep(500)
EndIf
If 
$status == False Then ExitLoop
WEnd
While 6
    
$result15 = _ImageSearch($Start_Bot_Game,1,$x1,$y1,100)
    If 
$result15 = 1 Then
MouseClick("
left",$x1,$y1,1)
Sleep(500)
EndIf
If 
$status == False Then ExitLoop
WEnd
While 7
    
$result16 = _ImageSearch($Annehmen,1,$x1,$y1,100)
    If  
$result16 = 1 Then
MouseClick("
left",$x1,$y1,1)
Sleep(1000)
EndIf
If 
$status == False Then ExitLoop
WEnd

Sleep(4000);hier suchst du für die champs die posis, schreibst sie aber ALLE in die selbe variable => nur die lezte posi wird gespeichert,dH teemo. alternativ leblanx_x,leblanc_y etc verwenden
$Leblanc = _ImageSearch("Leblanc.png",1,$x1,$y1,0)
$Katarina =_ImageSearch("Katarina.png",1,$x1,$y1,0)
$Teemo =_ImageSearch("Teemo.png",1,$x1,$y1,0)
$Darius =_ImageSearch("Darius.png",1,$x1,$y1,0)
$Akali = _ImageSearch("Akali.png",1,$x1,$y1,0)
$Morgana =_ImageSearch("Morgana.png",1,$x1,$y1,0)
$Shaco =_ImageSearch("Shaco.png",1,$x1,$y1,0)
$Garen = _ImageSearch("Garen.png",1,$x1,$y1,0)
$Vaigar =_ImageSearch("Vaigar.png",1,$x1,$y1,0)
$Teemo= InputBox("Champ Auswahl","Bitte wähle dir einen von den Champs aus:" &@CRLF& " -Teemo" &@CRLF& " -Darius" &@CRLF& " -Akali" &@CRLF& " -Morgana" &@CRLF& " -Shaco" &@CRLF& " -Garen" &@CRLF& " -Vaigar" &@CRLF& " -Katarina" &@CRLF& " -Leblanc")
Sleep(500)
While 18
$result10 = _ImageSearch("Bestätigen Champ.png",1,$x1,$y1,100)
If 
$result10 = 1 Then
    Sleep(500)
MouseClick("
left",1,$x1,$y1,1)
Sleep(500)
EndIf
If 
$status == False Then ExitLoop
WEnd
EndFunc

Func _Exit()
Exit
EndFunc

Func Stop()
While 1
If 
$status == False Then ExitLoop
ToolTip("
Afk Bot wurde gestoppt.Bitte klicken sie auf die Schaltfläche Exit.",0,0)
Sleep(600)
WEnd
EndFunc

Func TogglePause()
    
$Paused = NOT $Paused
    While 
$Paused
        sleep(500)
        ToolTip("
Bot wird pausiert!",0,0)
    WEnd
    ToolTip("
Pause beendet!",0,0)
    Sleep(1500)
    ToolTip("")
EndFunc 
Dankeschön für die Hilfe Ist das Sript überhaupt so richtig oder muss noch was verändert werden. Wenn ich auf F2 drücke die Schleife beginnt und wenn ich auf F5 gehe die Schleife beendet wird und wenn ich nochmal auf F2 drücke die Schleife dann wieder beginnt wie mache ich das? Und dann hab ich noch eine Frage wie genau müssen die Bilder sein damit das Programm(der Bot) das Bild überhaupt findet denn in der Demo der Imagesearch.zip funktioniert es sowohl mit dem Bild als auch wenn es auf dem Desktop ist. Ich hoffe das du mir dabei helfen kannst


Danke
LG Golle12
golle12 is offline  

Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.