AutoIt Script

11/21/2009 13:32 stefan654#1
hey guys, this is the beginning of a bot,
anyone could correct the errors out of it?
Quote:
HotKeySet("{F12}","startover") ;i allocate to key F12 the function start over
;i do this because when i exit the game the auto-hunt might be too fast for me to stop
; so i'll just press F12 and it will be stopped
; also u can add any key u want F1-12, NumPad0-9 ... and so on

startover() ; i call that same function to run so i just won't have to press F12

Func startover();i declare it

Endfunc ;and i end it

while 1; it will just keep the program in stand by untill the function is called
; useless in our case since we called the function automatically but it's good for u to know it
sleep(1000)
WEnd

while 1 ;because i want it to run over and over again
ProcessClose("hunt.exe") ;that's the auto-hunt i'll make later
ProcessClose("pot.exe") ;and the auto-pot i'll make later
;ProcessClose it basically just does what it says it closed a process
;what i do this ? because i don't want my auto-hunt and auto-pot to run more that once
;so each time the function initiate it will kill it?s *Sub-Functions*
Wend
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
while 1;we start a loop that wait for u to enter the game
PixelSearch(964,743,964,743,0xF7E52B,15) ; we look for the GOLD color we;collected . The last number ?15? it?s the pixel color range it can search
;so basically it doesn?t have to be the EXACT pixel
If NOT @error Then; PixelSearch color returns @error = 1 if the color ain?t found
;and 0 if the color is found
;NOT @error means @error = 0
;so if it founds that GOLD pixel it continues
Run("pot.exe"); run it
Run("hunt.exe") ; run it
Mouseclick("left",999,22,1); this will close the mini-map in 1024x768
ExitLoop ; it exists the current while loop
EndIf ; we close the IF
sleep(1000) ; it waits 1000 ms (1 second) before it continnues
Wend ; we close the while loop

;in less words this while loop will search for pixel over and over and over again
;until the pixel it?s found
;then it exit loop and it continues

EndFunc

;the best way is to use the same recognition system as before only the opposite way
;we don't want the GOLD pixel to be there
PixelSearch(964,743,964,743,0xF7E52B,15) ;same pixel search as before
$n = @error
while $n ;while the pixel is not found
Select
Case Hex(PixelGetColor(428,347),6) = "FEFEFE" and Hex(PixelGetColor(581,444),6) = "EEEEEE"
; the 2 pixels in the main menu
Sleep(200)
ProcessClose("hunt.exe") ; we close both the Sub-Functions
ProcessClose("pot.exe") ; we don't want keys to be pressed
;while it writes the password
Sleep(6000)
Send("{Enter}");just to be sure we try a log in before we right;the password. This will clear the pass field and leave it blank
Sleep(2000)
MouseClick("left",528,381,1,0) ; left click in the pass field
Sleep(200)
Send("PutYourPasswordHere") ;it will write the pass
Send("{Enter}");log in
Sleep(800)
MouseMove(950,650) ;move the mouse to a non-related point
; u can notice some useless things that i add to the script just to be sure the program will never fail
;next server list
Case Hex(PixelGetColor(457,572),6) = "EEEEEE"
Sleep(1000)
Send("{Right}");it collapse the server list
Send("{Down 1}"); the number will be sub-server u want 1-20
Sleep(200)
EndIf
;next is char list
Case Hex(PixelGetColor(755,575),6) = "55504A"; adaugi un Send("{Down}")
;before the next Send("{Enter}") u have to add Send("{Down x}") where
;x is 1 for the 2nd char, 2 for the 3rd char and so on
;u don't add anything if the char u wanna play with it's the 1st char
Send("{Enter}");it selects the char
ExitLoop 2; it exits 2 loops: the current one and the one that
;started the search for disconnect
EndSelect

PixelSearch(964,743,964,743,0xF7E52B,15)
$n = @error
Sleep(1000)
;this keeps the while loop running till success
wend
wend

while 1

$coord = PixelSearch(186,26,187,26,0xA00C00,1);looking for the HP pixel in a color;range of 1

If not @error Then;if the color is not found
Send ("{F11}") ;it presses F11
;in game Options -> Game -> unMark "Use numeric Keys"
;just trust me with this one

EndIf

Sleep(100) ; if we don't put this sleep the auto-pot will keep the CPU used 100%
WEnd


while 1;just keep the script alive
sleep(1000)
wend
11/21/2009 13:35 MoepMeep#2
This is NOT the autoit section.
11/21/2009 13:39 hoseta#3
Quote:
HotKeySet("{F12}","startover") ;i allocate to key F12 the function start over
;i do this because when i exit the game the auto-hunt might be too fast for me to stop
; so i'll just press F12 and it will be stopped
; also u can add any key u want F1-12, NumPad0-9 ... and so on

startover() ; i call that same function to run so i just won't have to press F12

Func startover();i declare it



while 1; it will just keep the program in stand by untill the function is called
; useless in our case since we called the function automatically but it's good for u to know it
sleep(1000)
WEnd

while 1 ;because i want it to run over and over again
ProcessClose("hunt.exe") ;that's the auto-hunt i'll make later
ProcessClose("pot.exe") ;and the auto-pot i'll make later
;ProcessClose it basically just does what it says it closed a process
;what i do this ? because i don't want my auto-hunt and auto-pot to run more that once
;so each time the function initiate it will kill it?s *Sub-Functions*
Wend
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
while 1;we start a loop that wait for u to enter the game
PixelSearch(964,743,964,743,0xF7E52B,15) ; we look for the GOLD color we;collected . The last number ?15? it?s the pixel color range it can search
;so basically it doesn?t have to be the EXACT pixel
If NOT @error Then; PixelSearch color returns @error = 1 if the color ain?t found
;and 0 if the color is found
;NOT @error means @error = 0
;so if it founds that GOLD pixel it continues
Run("pot.exe"); run it
Run("hunt.exe") ; run it
Mouseclick("left",999,22,1); this will close the mini-map in 1024x768
ExitLoop ; it exists the current while loop
EndIf ; we close the IF
sleep(1000) ; it waits 1000 ms (1 second) before it continnues
Wend ; we close the while loop

;in less words this while loop will search for pixel over and over and over again
;until the pixel it?s found
;then it exit loop and it continues

EndFunc

;the best way is to use the same recognition system as before only the opposite way
;we don't want the GOLD pixel to be there
PixelSearch(964,743,964,743,0xF7E52B,15) ;same pixel search as before
$n = @error
while $n ;while the pixel is not found
Select
Case Hex(PixelGetColor(428,347),6) = "FEFEFE" and Hex(PixelGetColor(581,444),6) = "EEEEEE"
; the 2 pixels in the main menu
Sleep(200)
ProcessClose("hunt.exe") ; we close both the Sub-Functions
ProcessClose("pot.exe") ; we don't want keys to be pressed
;while it writes the password
Sleep(6000)
Send("{Enter}");just to be sure we try a log in before we right;the password. This will clear the pass field and leave it blank
Sleep(2000)
MouseClick("left",528,381,1,0) ; left click in the pass field
Sleep(200)
Send("PutYourPasswordHere") ;it will write the pass
Send("{Enter}");log in
Sleep(800)
MouseMove(950,650) ;move the mouse to a non-related point
; u can notice some useless things that i add to the script just to be sure the program will never fail
;next server list
Case Hex(PixelGetColor(457,572),6) = "EEEEEE"
Sleep(1000)
Send("{Right}");it collapse the server list
Send("{Down 1}"); the number will be sub-server u want 1-20
Sleep(200)

;next is char list
Case Hex(PixelGetColor(755,575),6) = "55504A"; adaugi un Send("{Down}")
;before the next Send("{Enter}") u have to add Send("{Down x}") where
;x is 1 for the 2nd char, 2 for the 3rd char and so on
;u don't add anything if the char u wanna play with it's the 1st char
Send("{Enter}");it selects the char
ExitLoop 2; it exits 2 loops: the current one and the one that
;started the search for disconnect
EndSelect

PixelSearch(964,743,964,743,0xF7E52B,15)
$n = @error
Sleep(1000)
;this keeps the while loop running till success
wend

while 1

$coord = PixelSearch(186,26,187,26,0xA00C00,1);looking for the HP pixel in a color;range of 1

If not @error Then;if the color is not found
Send ("{F11}") ;it presses F11
;in game Options -> Game -> unMark "Use numeric Keys"
;just trust me with this one

EndIf

Sleep(100) ; if we don't put this sleep the auto-pot will keep the CPU used 100%
WEnd


while 1;just keep the script alive
sleep(1000)
wend

but idk its will work
11/21/2009 14:33 Timo264#4
please use tabs
it is much easier to understand the level of the function

Quote:
HotKeySet("{F12}","startover") ;i allocate to key F12 the function start over
;i do this because when i exit the game the auto-hunt might be too fast for me to stop
; so i'll just press F12 and it will be stopped
; also u can add any key u want F1-12, NumPad0-9 ... and so on

startover() ; i call that same function to run so i just won't have to press F12

Func startover();i declare it

Endfunc ;and i end it

while 1; it will just keep the program in stand by untill the function is called
; useless in our case since we called the function automatically but it's good for u to know it
sleep(1000)
WEnd

while 1 ;because i want it to run over and over again
ProcessClose("hunt.exe") ;that's the auto-hunt i'll make later
ProcessClose("pot.exe") ;and the auto-pot i'll make later
;ProcessClose it basically just does what it says it closed a process
;what i do this ? because i don't want my auto-hunt and auto-pot to run more that once
;so each time the function initiate it will kill it?s *Sub-Functions*
Wend
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
while 1;we start a loop that wait for u to enter the game
PixelSearch(964,743,964,743,0xF7E52B,15) ; we look for the GOLD color we;collected . The last number ?15? it?s the pixel color range it can search
;so basically it doesn?t have to be the EXACT pixel
If NOT @error Then; PixelSearch color returns @error = 1 if the color ain?t found
;and 0 if the color is found
;NOT @error means @error = 0
;so if it founds that GOLD pixel it continues
Run("pot.exe"); run it
Run("hunt.exe") ; run it
Mouseclick("left",999,22,1); this will close the mini-map in 1024x768
ExitLoop ; it exists the current while loop
EndIf ; we close the IF
sleep(1000) ; it waits 1000 ms (1 second) before it continnues
Wend ; we close the while loop

;in less words this while loop will search for pixel over and over and over again
;until the pixel it?s found
;then it exit loop and it continues


;the best way is to use the same recognition system as before only the opposite way
;we don't want the GOLD pixel to be there
PixelSearch(964,743,964,743,0xF7E52B,15) ;same pixel search as before
$n = @error
while $n ;while the pixel is not found
Select
Case Hex(PixelGetColor(428,347),6) = "FEFEFE" and Hex(PixelGetColor(581,444),6) = "EEEEEE"
; the 2 pixels in the main menu
Sleep(200)
ProcessClose("hunt.exe") ; we close both the Sub-Functions
ProcessClose("pot.exe") ; we don't want keys to be pressed
;while it writes the password
Sleep(6000)
Send("{Enter}");just to be sure we try a log in before we right;the password. This will clear the pass field and leave it blank
Sleep(2000)
MouseClick("left",528,381,1,0) ; left click in the pass field
Sleep(200)
Send("PutYourPasswordHere") ;it will write the pass
Send("{Enter}");log in
Sleep(800)
MouseMove(950,650) ;move the mouse to a non-related point
; u can notice some useless things that i add to the script just to be sure the program will never fail
;next server list
Case Hex(PixelGetColor(457,572),6) = "EEEEEE"
Sleep(1000)
Send("{Right}");it collapse the server list
Send("{Down 1}"); the number will be sub-server u want 1-20
Sleep(200)

;next is char list
Case Hex(PixelGetColor(755,575),6) = "55504A"; adaugi un Send("{Down}")
;before the next Send("{Enter}") u have to add Send("{Down x}") where
;x is 1 for the 2nd char, 2 for the 3rd char and so on
;u don't add anything if the char u wanna play with it's the 1st char
Send("{Enter}");it selects the char
ExitLoop 2; it exits 2 loops: the current one and the one that
; started the search for disconnect
EndSelect

PixelSearch(964,743,964,743,0xF7E52B,15)
$n = @error
Sleep(1000)
;this keeps the while loop running till success
wend

while 1

$coord = PixelSearch(186,26,187,26,0xA00C00,1);looking for the HP pixel in a color;range of 1

If not @error Then;if the color is not found
Send ("{F11}") ;it presses F11
;in game Options -> Game -> unMark "Use numeric Keys"
;just trust me with this one

EndIf

Sleep(100) ; if we don't put this sleep the auto-pot will keep the CPU used 100%
WEnd


while 1;just keep the script alive
sleep(1000)
wend
it works for me, i can start it
11/21/2009 16:29 stefan654#5
Quote:
Originally Posted by MoepMeep View Post
This is NOT the autoit section.
As far as i know this forum is ment to get help/hacks/etc for games?
hmm
TheCode i gave here is a start for a hack...so i don't know why this should
be posted wrong -.-
Anyway, anyone got the
values for pink mobs(which u get when deleted the tex map)
?
I kindy need it to make it work :p
This is for the Attacking:
$xTop = Number; i declare them
$yTop = Number
$xBot = Number
$yBot = Number
$mobGreen = "PinkValue"; i also declare the mob color

I need values for number/pink value :o
thanks =)
(the bot searches already, but it doesn't find any mobs cause of no pixels set) :p
11/21/2009 16:29 stefan654#6
Quote:
Originally Posted by Timo264 View Post
please use tabs
it is much easier to understand the level of the function



it works for me, i can start it
kk thanks, it does now for me aswell :p
11/21/2009 16:48 bloodx#7
wow even for AutoIT its kinda ugly+bad written oO here is already a AutoIT bot u can download it ~.~
11/21/2009 16:57 MoepMeep#8
Quote:
Originally Posted by stefan654 View Post
As far as i know this forum is ment to get help/hacks/etc for games?
hmm
TheCode i gave here is a start for a hack...so i don't know why this should
be posted wrong -.-
coz this is NOT the autoit section
11/21/2009 17:14 stefan654#9
Quote:
Originally Posted by bloodx View Post
wow even for AutoIT its kinda ugly+bad written oO here is already a AutoIT bot u can download it ~.~
i'm not a guy who just leaches everything -.-
Those released things get detected fast
11/21/2009 17:42 Timo264#10
value for pink mobs
if you mean the Hex code
it is FE01FE
11/22/2009 01:29 katze123#11
and autoit is blocked by the hackshield ? :-D i dunno sry
11/22/2009 11:37 meak1#12
no ;< workZ
11/22/2009 13:06 katze123#13
stimmt du hattest ja mal gesagt wie :-D
11/22/2009 16:30 meak1#14
ne ;D , früher ging autoit nicht bei kal aber kp was die nubs gemacht haben^^ ,autoit ging wieder glaube so mitte 2009 kp mehr
11/22/2009 18:40 dragonsnider#15
Quote:
Originally Posted by stefan654 View Post
i'm not a guy who just leaches everything -.-
Those released things get detected fast
detected??? whahahhahahahhahahahahhahahaha epic fail :mofo::mofo: