Farmbot - For 64 Bit OS

02/03/2010 19:35 schmuselord1#121
this is how i got my bot done: (editing the autors code)

Code:
HotKeySet("{NUMPAD1}", "combo") ;to start application
HotKeySet("{NUMPAD2}", "pause") ;to pause it
HotKeySet("{NUMPAD3}", "ende") ;to exit bot

Global $timerinit = TimerInit() ; timer
Global $timerinit2
Global $timerinit3 = TimerInit()
Global $timerinit4 = TimerInit()
Global $character = 2 ; 1 = priest, 2 = breeder
Global $total
Global $hours
Global $minutes
Global $minutes2
Global $minutes3 = 0
Global $seconds
Global $seconds2
Global $seconds3 = 0
Global $funktionan = False ;bot initialized while pause
Global $average = 0
Global $average2 = 0
Global $maus
Global $mytimer = 0
Global $moven
Global $drehung ; to turn around
Global $mobhealth
Global $mobhealthonethird
Global $bottrap
Global $bottrap2
Global $bottrap3
Global $bottrap4
Global $bottrap5
Global $highesttime = 0
Global $timerinit
Global $timer
Global $health1
Global $health1110
Global $health114
Global $health145
Global $mana
Global $health2
Global $health3
Global $health4
Global $killcounter
Global $randomclick = Random ( 1, 4, 1 )
Global $restorationcounter = 0
Global $rapidhealcounter = 0
Global $lastencounteredmob = 0
Global $acidspraycounter = 0
Global $sleepcounter = 0
Global $disccounter = 0
Global $potcounter = 0
Global $cooldown[12] ;cooldown for skills
$cooldown[1] = 31000 ; cd for acidspray
$cooldown[2] = 33000 ; cd for restoration
$cooldown[3] = 60000 ; cd for red pot
$cooldown[4] = 16000 ; cd for minor heal
Global $recentlyusedskill[12] ;array for skills
$recentlyusedskill[1] = 0 ; lastused acidspray
$recentlyusedskill[2] = 0 ; lastused restoration
$recentlyusedskill[3] = 0 ; lastused red pot
$recentlyusedskill[4] = 0 ; lastused minor heal
Global $sleeprandomtab = Random ( 100 , 200 , 1 )
Global $sleeprandohundred = Random ( 80 , 120 , 1 )
Global $sleepbufftwentyfive = Random ( 1450000 , 1550000 , 1 )
Global $sleeptimerinit2 = Random ( 15000 , 20500 , 1 )
Global $sleeptimerinit3 = Random ( 8000, 13000, 1 )
Global $sleeploot1 = Random ( 999 , 1501 , 1 )
Global $sleeploot2 = Random ( 399 , 699 , 1 )
Global $sleeploot3 = Random ( 149, 249, 1)
Global $sleepcamera = Random ( 10 , 20 , 1 )
Global $sleepbuff = Random ( 1750 , 1900, 1 )
Global $sleepattack = Random ( 2100, 3100, 1 )
Global $delay = Random ( 1000, 1500, 1 )
Global $sleepheal = Random ( 2500, 3000, 1 )
Global $sleeprandomcam2 = Random ( 499, 599, 1 )
Global $randomonetofive = Random ( 1, 5, 1 )
Global $mobhealthfull
Global $mobhealthempty
Global $confirmcolor1
Global $confirmcolor2
Global $iconcolor
Global $iconcolor2
Global $helptimer = True
Global $helpbuffready
Global $helpbuffready2 = 0
Global $helpmana = 0

Func readcolor()
	$iconcolor = PixelGetColor(15, 25); icon color ^^
	$iconcolor2 = PixelGetColor(22, 36); icon color char 2
	$health1 = PixelGetColor(108, 57) ;color of char left
	$health2 = PixelGetColor(114, 117); creature hp
	$health1110 = PixelGetColor(28, 53)
	$health114 = PixelGetColor(66, 52); if your hp is below 1/4
	$health145 = PixelGetColor(170, 55); if your hp is below 4/5
	$health4 = PixelGetColor(486, 422) ;shows confirm by death (didnt implement it yet)
	$mana = PixelGetColor(70, 67); mana of char
	$mobhealthempty = PixelGetColor(1070, 30) ;check if mob still got life
	$mobhealthfull = PixelGetColor(1261, 29); if mob is full life
	$bottrap = PixelGetColor(1022, 5) ;check on mob trap
	$bottrap2 = PixelGetColor(1013, 4) ;check on mob trap
	$bottrap3 = PixelGetColor(1022, 15) ;check on mob trap
	$bottrap4 = PixelGetColor(1020, 10)
	$bottrap5 = PixelGetColor(1020, 11)
	$mobhealthonethird = PixelGetColor(1122, 29); if mob has 1/3 hp
	$confirmcolor1 = PixelGetColor(704, 431) ; if you got a disconnect
	$confirmcolor2 = PixelGetColor(856, 434) ; if you got a disconnect
	Sleep( $sleepcamera )
EndFunc   ;==>read colors

Func readcolorrelog()
	$health1 = PixelGetColor(620, 296) ; overrides temporarily health1. didnt want to use too many variables; for startbutton
	$health2 = PixelGetColor(597, 241) ; for startbutton
	$health1110 = PixelGetColor(651, 576) ; for accountrecognition
	$health114 = PixelGetColor(948, 670) ; for accountrecognition
	$health145 = PixelGetColor(982, 170) ; for char login
	$health4 = PixelGetColor(1260, 176) ; for char login
	$confirmcolor1 = PixelGetColor(769, 431) ; if you you are already logged in
	$confirmcolor2 = PixelGetColor(868, 431) ; if you you are already logged in
EndFunc

Func gostandby()
	;Shutdown(36) ; standby modus - only one modus should be active. otherwise the first one will be used
	Shutdown(5) ; shuts pc down by force xD
EndFunc
	
Func relogacc()
	Opt("PixelCoordMode", 1)
	Opt("MouseCoordMode", 1)
	RunWait(@COMSPEC & " /c Start Rappelz.lnk ") ; listen! you have to make a link from the original "Launcher.exe" from rappelz and copy it into your folder. it should be named "Rappelz"
	SendKeepActive("Launcher")
	Opt("PixelCoordMode", 2)
	Opt("MouseCoordMode", 2)
	readcolorrelog()
	While Hex($health1, 6) <> "C82109" And Hex($health2, 6) <> "C82519" ; if the big red start button is not ready yet
		readcolorrelog()
		Sleep(1500)
		$sleepcounter += 1
		If $sleepcounter == 8 Then
			gostandby()
		EndIf
	WEnd
	$sleepcounter = 0
	sleep(3000)
	MouseClick( "left", 620, 296, 1 )
	Sleep(8000) ; increase this value of your computer is too slow! 8000 = 8 sec
	readcolorrelog()
	While Hex($health1110, 6) <> "9E9F9E" And Hex($health114, 6) <> "91908E" ; if havent reached account-input window yet xD
		readcolorrelog()
		sleep(1000)
		$sleepcounter += 1
		Send("{ESC}")
		If $sleepcounter == 20 Then
			gostandby()
		EndIf
	WEnd
	sleep(2500)
	$sleepcounter = 0
	If $character == 1 Then
		Send("accountpriest") ;write your accountname
		Sleep(500)
		Send("{TAB}")
		sleep(50)
		Send("password") ;write your password
		sleep(500)
		Send("{ENTER}")	
	Else
		Send("accountbreeder") ;write your accountname
		Sleep(500)
		Send("{TAB}")
		sleep(50)
		Send("password") ;write your password
		sleep(500)
		Send("{ENTER}")	
	EndIf
	sleep(2000)
	readcolorrelog()
	If Hex($confirmcolor1, 6) == "FBE7B4" And Hex($confirmcolor2, 6) == "FBE7B4" Then ; if someone is already logged in
		While Hex($confirmcolor1, 6) == "FBE7B4" And Hex($confirmcolor2, 6) == "FBE7B4" ; while someone is already logged in the bot tries it again
			MouseClick( "left", 800, 478, 1 )
			Sleep( $sleeptimerinit3 )
			MouseClick( "left", 862, 652, 1 )
			sleep(2000)
			readcolorrelog()
			$sleepcounter += 1
			If $sleepcounter == 20 Then
				gostandby()
			EndIf
		WEnd
		$sleepcounter = 0
	EndIf
	If $character == 1 Then
		Send("{DOWN}") ; selects server. 2x down means naga - 3x down means fenrir server
		sleep(500)
		Send("{DOWN}")
		sleep(400)
	Else
		Send("{UP}")
		sleep(500)
	EndIf
	Send("{ENTER}")
	readcolorrelog()
	While Hex($health145, 6) <> "C6C5C5" And Hex($health4, 6) <> "7E7F7A" ; if your character doesnt show up in loggin-area
		sleep(1000)
		readcolorrelog()
		$sleepcounter += 1
		If $sleepcounter == 10 Then
			gostandby()
		EndIf
	WEnd
	$sleepcounter = 0
	Send("{ENTER}")
	readcolor()
	While Hex($iconcolor, 6) <> "9E9A41" Or Hex($iconcolor2, 6) <> "FDFFFA" ; - while you cant see your character icon
		sleep(2000)
		readcolor()
		$sleepcounter += 1
		If $sleepcounter == 10 Then
			gostandby()
		EndIf
	WEnd
	$sleepcounter = 0
	$mytimer = 0
	$lastencounteredmob = TimerDiff($timerinit3)
	combo() ; yea. lets go to main function and keep on botting xD
EndFunc

Func ifdisconnect()
	readcolor()
	If Hex($confirmcolor1, 6) == "FBE7B4" And Hex($confirmcolor2, 6) == "FBE7B4" Then ; if a disconnect shows up
		sleep(200)
		$disccounter += 1
		MouseClick( "left", 775, 478, 1 )
		Sleep(15000)
		relogacc() ; either relogacc or gostandby shall be active. otherwise relogacc will be used
		;gostandby() ; only one of them shall be active. otherwise relogacc will be used
	EndIf
EndFunc

Func tabben()
	Send("{TAB}")
	Sleep( $sleeprandomtab )																																																																																																																																																																																																														
EndFunc   ;==>tabben tabfunction

Func loot()
	Sleep( $sleeprandohundred )
	Send("{Space}")
	Sleep( $sleeploot1 )
	Send("{Space}")
	Sleep( $sleeploot3 )
	Send("{Space}")
	Sleep( $sleeploot3 )
	Send("{Space}")
	Sleep( $sleeploot3 )
	Send("{Space}")
	Sleep( $sleeploot3 )
	Send("{Space}")
	Sleep( $sleeploot3 )
	Send("{Space}")
EndFunc   ;==>loot lootfunktion if no lootpet available

Func turncamera()
	MouseMove(520, 380)
	MouseDown("right")
	MouseMove(900, 380)
	MouseUp("right")
;	Mouseclick("left")
	Sleep( $sleepcamera )
EndFunc   ;==>turns around the camera

Func move()
	MouseMove(800, 350)
	MouseClick("left")
	Sleep( $sleepcamera )
EndFunc   ;==>move direction

Func buff1ready()
	If ( $mytimer == 0 ) Then
		Return True
	EndIf
	$helpbuffready = TimerDiff($timerinit3)
	if ( ($helpbuffready - $helpbuffready2) >= $sleepbufftwentyfive ) Then   ; buffs which have more than 25min cd
		$helpbuffready2 = $helpbuffready
		;$timehelp = True
		Return True
	EndIf
EndFunc  

Func buff2ready()
	If ($timer - $recentlyusedskill[3]) >= $cooldown[3] Then
		Return True
	EndIf
EndFunc   ;==>buffready

Func buffen()  ; buffs with 30 min cooldown
	Send("{ESC}")
	sleep ( $sleeprandohundred )
	Send("{ESC}")
	sleep ( $sleeprandohundred )
	If 	$mytimer == 0 Then  ; permanent buffs
		If $character == 1 Then
			Send("{ALTDOWN}3{ALTUP}"); alt + 3
			Sleep( $sleeploot3 )
			Send("{SHIFTDOWN}9{SHIFTUP}"); shift + 6
			sleep( $sleepbuff )
			SLeep( $delay )
		Else
			Send("{SHIFTDOWN}8{SHIFTUP}")
			sleep( $sleepbuff )
			SLeep( $delay )
		EndIf
		$mytimer = 1
	EndIf
	If $character == 1 Then
		Send("{SHIFTDOWN}1{SHIFTUP}"); shift + 1
		Sleep( $sleepbuff )
		SLeep( $delay )
		Send("{SHIFTDOWN}2{SHIFTUP}"); shift + 2
		Sleep( $sleepbuff )
		SLeep( $delay )
		Send("{SHIFTDOWN}3{SHIFTUP}"); shift + 3
		SLeep( $sleepbuff )
		SLeep( $delay )
		Send("{SHIFTDOWN}4{SHIFTUP}"); shift + 4
		Sleep( $sleepbuff )
		SLeep( $delay )
		Send("{SHIFTDOWN}5{SHIFTUP}"); shift + 5
		Sleep( $sleepbuff )
		SLeep( $delay )
		Send("{SHIFTDOWN}6{SHIFTUP}"); shift + 5
	Else
		; coming soon
	EndIf
	$recentlyusedskill[5] = $timer
EndFunc   ;==>buffen use buff

Func acidspray() ; function for acid spray if you got enough mana to waste
	If $character == 1 Then
		$helpmana = TimerDiff($timerinit3) 
		If ( Hex($mana, 6) == "8499C3" And ( $helpmana - $recentlyusedskill[1] ) > $cooldown[1] And Hex($mobhealthonethird, 6) == "C6776A") Then
			$acidspraycounter += 1
			$recentlyusedskill[1] = $helpmana
			Send("6")
			sleep( $sleepbuff )
			Send("2")
			Sleep( $sleeprandomcam2 )
			Send("2")
		EndIf
	EndIf
EndFunc

Func restoration() ; function for restoration
	If $character == 1 Then
		$helpmana = TimerDiff($timerinit3)
		If ( $helpmana - $recentlyusedskill[2] ) > $cooldown[2] And Hex($health145, 6) <> "B7D990" Then
			$restorationcounter += 1
			$recentlyusedskill[2] = $helpmana
			MouseClick( "left", 170, 55, 1 )
			sleep( $sleepcamera )
			Send("7")
			sleep( $sleepbuff )
		EndIf
	EndIf
EndFunc

Func pot()
	If $character <> 1 Then
		$helpmana = TimerDiff($timerinit3)
		If ( $helpmana - $recentlyusedskill[3] ) > $cooldown[3] And Hex($health145, 6) <> "B7D990" Then
			$recentlyusedskill[3] = $helpmana
			Send("{CTRLDOWN}9{CTRLUP}")
			$potcounter += 1
		EndIf
	EndIf
EndFunc
	
Func rapidheal() ; function for rapidheal
	If $character == 1 Then
		If Hex($health114, 6) == "150907" Then
			restoration()
			$rapidhealcounter += 1
			MouseClick( "left", 170, 55, 1 )
			sleep( $sleepcamera )
			Send("9")
			sleep( $sleepheal )
			Send("9")
			sleep( $sleepheal )
			kson()
		EndIf
	EndIf
EndFunc

Func quitifhplow()
	If Hex($health1110, 6) == "1C0D0A" Then
		MouseClick( "left", 1576, -21, 1 )
		sleep( $sleeprandomtab )
		MouseClick( "left", 729, 247, 1 )
		Shutdown(5)
	EndIf
EndFunc	

Func timestatistic() ; average and highest time you need to attack another mob
	$helpmana = TimerDiff($timerinit3)
	$lastencounteredmob = $helpmana - $lastencounteredmob
	$average = $lastencounteredmob + $average 
	$average2 = $average / 1000 / ( $killcounter + 1 )
	$minutes2 = Round(( $average2 / 60 ), 0)
	$seconds2 = Mod( Round( $average2, 0 ), 60 )
	If $highesttime < ( $lastencounteredmob / 1000 ) Then
		$highesttime = $lastencounteredmob / 1000
		$minutes3 = Round(( $highesttime / 60 ), 0)
		$seconds3 = Mod( Round( $highesttime, 0 ), 60 ) 
	EndIf
EndFunc

Func timestatistic2() ;how long the script is running
	$helpmana = TimerDiff($timerinit3)
	$seconds = Mod( Round(( $helpmana / 1000 ), 0), 60 )  
	$minutes = Mod( Round(( $helpmana / 1000 / 60 ), 0), 60 )
	$hours = Round( $helpmana / 1000 / 3600, 0 )
	$total = Round( $killcounter / ( $helpmana / 1000 / 60 ), 2 )
EndFunc

Func writefile() ; writes the log :D
	$file = FileOpen("log.txt", 10)
	If $character == 1 Then
		FileWrite($file, "Priest" & @CRLF & @CRLF)
	Else
		FileWrite($file, "Breeder" & @CRLF & @CRLF)
	EndIf
	FileWrite($file, "Total kills: 	" & $killcounter & @CRLF & @CRLF)
	FileWrite($file, "How long the script is running: " & $hours & " Hours " & $minutes & " Minutes " & $seconds & " Seconds" & @CRLF & @CRLF)
	FileWrite($file, "Average time of encountering mob: " & $minutes2 & " Minutes " & $seconds2 & " Seconds" & @CRLF & @CRLF)
	FileWrite($file, "Highest time of encountering mob: " & $minutes3 & " Minutes " & $seconds3 & " Seconds" & @CRLF & @CRLF)
	FileWrite($file, "Kills per minute: " & $total & @CRLF & @CRLF)
	FileWrite($file, "Rapidhealcounter: " & $rapidhealcounter & "		restorationcounter: " & $restorationcounter & "		acidspraycounter: " & $acidspraycounter & "		potcounter :" & $potcounter & @CRLF & @CRLF)
	FileWrite($file, "disconnects: " & $disccounter)
	FileClose($file)
EndFunc

Func attack()
	timestatistic() ; average and highest time you need to attack another mob
	If $character == 1 Then
		Send("3")
		Sleep( $sleepattack )
		Send("2")
	Else
		Send("2")
		Sleep( $sleeploot2 )
		Send("3")
		sleep( $sleepbuff )
		Send("2")
		Sleep( $sleeprandohundred )
		Send("2")
		Sleep( $sleeprandohundred )
	EndIf
	Sleep( $sleeploot1 )
	$drehung = 0
	$moven = 0
	$timerinit2 = TimerInit()
	While Hex($mobhealthempty, 6) == "C8A78A" ; if mob is not dead yet
		sleep(250)
		If $randomclick == 4 Then
			Send("2")
		EndIf
		ifdisconnect()
		pot()
		quitifhplow()
		acidspray()
		rapidheal()
		If TimerDiff($timerinit2) > $sleeptimerinit2 And Hex($mobhealthfull, 6) == "C6776A" Then ; if char got stuck ((maybe mob is in a wall)
			Send("{ESC}")
			move()
			sleep( $sleeprandomcam2 )
			turncamera()
			Sleep( $sleeprandomcam2 )
			move()
		EndIf
		If Hex($mobhealthempty, 6) <> "C8A78A" Then
		loot()
		$timerinit2 = 0
		$killcounter = $killcounter + 1
		timestatistic2() ;how long the script is running
		writefile() ; writes data into a file in the same folder where your script is
		$lastencounteredmob = TimerDiff($timerinit3); resets lastencounteredmob because the mob is dead now ^^
		EndIf
	WEnd
EndFunc

Func combo() ;main bot loop
	$funktionan = True
	SendKeepActive("Rappelz")	;Rappelz always in foreground
	Opt("PixelCoordMode", 2)	;pixel directly read from client
	Opt("MouseCoordMode", 2)	;mouse only moves in client
	While $funktionan = True
		ifdisconnect()
		If Hex($iconcolor, 6) == "9E9A41" Then
			$character = 2
		Else
			$character = 1
		EndIf
		quitifhplow()
		If Hex($health1, 6) == "7B8A3E" Then ; char color must be green
			If buff1ready() == True Then buffen()
			If Hex($mobhealthfull, 6) == "C6776A" Then ;mob health must be red and full (prevents ks)
				If Hex($bottrap, 6) <> "A780FD" And Hex($bottrap2, 6) <> "A780FD" And Hex($bottrap3, 6) <> "A780FD"  And Hex($bottrap4, 6) <> "A780FD" And Hex($bottrap5, 6) <> "A780FD" Then
					attack()
					restoration()
				Else
					ifdisconnect()
					quitifhplow()
					tabben()
					$drehung = $drehung + 1
					If $drehung > 2 Then
						turncamera()
						$drehung = 0
						$moven = $moven + 1
					EndIf
					If $moven > 5 Then
						move()
						$moven = 0
					EndIf
				EndIf
			Else
				ifdisconnect()
				quitifhplow()
				tabben()
				$drehung = $drehung + 1
				If $drehung > 2 Then
					turncamera()
					$drehung = 0
					$moven = $moven + 1
				EndIf
				If $moven > 5 Then
					move()
					$moven = 0
				EndIf
			EndIf
		Else
			ifdisconnect()
			quitifhplow()
			If $character == 1 Then
				MouseClick( "left", 170, 55, 1 )
				Sleep( $sleepcamera	)
				Send("8")
			Else
				Send("9")
			EndIf
			sleep( $sleepheal )
		EndIf
		if Hex($health2, 6) <> "9FBA68" Then; if your pet is below half hp
			MouseClick( "left", 114, 117, 1 ) 
			Send("8")
			sleep( $sleepheal )
		EndIf			
	WEnd
EndFunc   ;==>combo

Func kson() ;kson bot loop
	SendKeepActive("Rappelz")	;Rappelz always in foreground
	Opt("PixelCoordMode", 2)	;pixel directly read from client
	Opt("MouseCoordMode", 2)	;mouse only moves in client
	While $funktionan = True
		ifdisconnect()
		quitifhplow()
		If Hex($mobhealthempty, 6) == "C8A78A" Then ; if mob is not dead yet
			If Hex($bottrap, 6) <> "A780FD" And Hex($bottrap2, 6) <> "A780FD" And Hex($bottrap3, 6) <> "A780FD"  And Hex($bottrap4, 6) <> "A780FD" And Hex($bottrap5, 6) <> "A780FD" Then
				attack()
				restoration()
			Else
				ifdisconnect()
				quitifhplow()
				tabben()
				$drehung = $drehung + 1
				If $drehung > 2 Then
					turncamera()
					$drehung = 0
					$moven = $moven + 1
				EndIf
				If $moven > 5 Then
					move()
					$moven = 0
				EndIf
			EndIf
		Else
			ifdisconnect()
			quitifhplow()
			tabben()
			readcolor()
			If Hex($mobhealthempty, 6) <> "C8A78A" Then
				combo()
			EndIf
			$drehung = $drehung + 1
			If $drehung > 2 Then
				turncamera()
				$drehung = 0
				$moven = $moven + 1
			EndIf
			If $moven > 5 Then
				move()
				$moven = 0
			EndIf
		EndIf
		if Hex($health2, 6) <> "9FBA68" Then; if your pet is below half hp
			MouseClick( "left", 114, 117, 1 ) 
			Send("8")
			sleep( $sleepheal )
		EndIf			
	WEnd
EndFunc   ;==>kson

Func pause()
	$funktionan = False
	Sleep(10)
EndFunc   ;==>pause

Func ende()
	Exit
EndFunc   ;==>ende

While 1
	Sleep(50)
WEnd
little description: (first of all it is an edit from the author's code)
-works only if the rappelz-client has 1600x900 resolution
-attacks mobs
-loots
-doesnt steal kills
-detects bot traps
-uses skills
-relogs or shuts your pc down on wish if you got a disconnect
-writes log files about kills, average time to encounter a mob, highest time, skillcounter etcs
-moves if there is no mob available (but you cant compare it with pathing; move-function is immature)
-heals yourself and your pet outside the fight with heal and restoration; also uses rapidheal in dangerous situations infight. but this situation has not throughoutly been tested

current settings for priest:

2 - creature and player attack
3 - creature attacks
6 - acid spray
7 - restoration
8 - heal
9 - rapidheal
shift+1 blessing of vit
shift+2 blessing of str
shift+3 blessing of int
shift+4 blessing of wis
shift+5 shining weapin
shift+6 minor shining armor
shift+9 mass mp reg (permanent buff)
alt + 3 unity (creature; permanent buff)

current settings for breeder:

2 - creature and player attack
8 - creature heal
9 - minor heal
shift + 8 str support
ctrl + 9 red pot

just pm me if you got any questions

edit 1: yooo. updated the edited script. now it helps to prevent obvious cases of killstealing + a raw anti-stuck help and some smaller improvements
edit 2: i had troubles with resetting the timer so i solved the problem in a mathematic way - rebuffing works very well at the moment ^^
edit 3: reinitialized manacolorread - if there is mana to waste, acid spray will be used if its ready
edit 4: uses rapid heal and restoration (but doesnt work all too well yet)
edit 5: restoration and rapid heal work properly so far. had to use another main function to resume fight after using rapid heal while fighting
edit 6: added a log file for total kills, kills per minute, how long the script was running until shutdown, average time until you encountered a mob, highest time you needed to encounter a mob.
the only problem is that the mathematics are surely messed up. total kills and highest time you needed to encounter a mob work. the rest does not :P but if i got some time i will repair the other information
edit 7: statistics are alright now! :D
edit 8: initialized a relog if you got a disconnect! you can choose either to relog or to standby your computer if you got one. how to setup your acc data and how to choose the server can be seen within the code-descriptions
edit 9: initialized breeder. script autodetects if its a breeder or priest and uses specific settings

btw - if you want me to set up the bot completely for your character and you dont want to do it yourself: i will most probably do it, but under 2 conditions:
-1st: your character is on unicorn server
-2nd: ill get some percentage from the drops you get while botting

but if youre stuck and you only need a little help you can contact me too :) ill help if i have time
02/06/2010 01:33 Dark661#122
hello
i dont know but i didnt get the bot working right
my problem is that my skills dont work :S
i have an cm and so i just want to use fire arrow and lightning bolt
i allready readed the other 12 pages but the little "how to's" are not really easy to understand :S
may if anyone can give me a little example for cm settings it would be cool ^^
02/06/2010 17:43 schmuselord1#123
which hotkeys do you use for fire arrow and lightning? and which part dont you understand?

Code:
Func skill1bereit()
    If ($timer - $skillzuletztgenutzt[1]) >= $cooldown[1] Then
        Return True
you must read this to understand it.
theres a timer at the beginning. so if your timer - your last used spell is greater than your cooldown then the function is true.

and if the function is true then :

Code:
 If skill1bereit() = True Then
                    Send("{F3}")
                    Sleep(50)
                    $skillzuletztgenutzt[1] = $timer
that means. if skill1 is true (ready; cooldown is over) then you cast your spell (which is on F3). but you could also choose Send("{SHIFTDOWN}1{SHIFTUP}") instead of Send("{F3}"). that means the script holds shift and presses 1 (shift + 1).

and there you go. you can do that with more than just one spell.

example:
(global section)
Code:
Global $cooldown[1]  = 10000
(if fire arrow needs 10 sec cooldown)
Code:
Global $cooldown[2]  = 8000
(if lightning bolt needs 8 sec cd)

(function section)
for fire arrow
Code:
Func skill1bereit()
If ($timer - $skillzuletztgenutzt[1]) >= $cooldown[1] Then
Return True EndIf  EndFunc
for lightning bolt
Code:
Func skill2bereit()
If ($timer - $skillzuletztgenutzt[2]) >= $cooldown[2] Then
Return True EndIf  EndFunc
(main function)
Code:
If Hex($chip, 6) = $chipfarbe Then 
Send("{F1}")
Sleep(1300)
lets say this one is your start (a spell that has no cooldown; spell shouldnt have more than 1 sec casting time (due to delay)

the script goes on:

Code:
If skill1bereit() = True Then
                    Send("{F3}")
                    Sleep(2300)
                    $skillzuletztgenutzt[1] = $timer
                EndIf 
If skill2bereit() = True Then
                    Send("{F4}")
                    Sleep(1800) 
                    $skillzuletztgenutzt[2] = $timer
                EndIf
if you use it like this in your main function then you:
-wait until the cooldown of your spell is over
-if cooldown[1] is gone you cast firearrow
-you wait 2 sec + 300 ms delay
-if cooldown[2] is gone you cast lightning bolt
-you wait 1,5 sec + 300 ms delay

and afterwards the script goes on with the rest of the procedure... its that simple
02/08/2010 09:34 Notorious009#124
no idea wat hes talkin bout..any1 translate please
02/09/2010 06:43 schmuselord1#125
Quote:
Originally Posted by Notorious009 View Post
no idea wat hes talkin bout..any1 translate please
lol. who are you referring to? and to which post?
02/15/2010 11:16 schmuselord1#126
my newest log ^^ its incredible. got 3 e cards within 5 hours. bot rules xD

Total kills: 1000

How long the script is running: 5 Hours 14 Minutes 1 Seconds

Average time of encountering mob: 0 Minutes 5 Seconds

Highest time of encountering mob: 3 Minutes 52 Seconds

Kills per minute: 3.18

Rapidhealcounter: 0 restorationcounter: 0 acidspraycounter: 483
02/17/2010 23:43 schmuselord1#127
does anyone use my script or can i stop updating it in the forum?
02/18/2010 18:20 KentuckyFC#128
You get owned by KentuckyFC

Its the original bot from JTremblay so stfu these are Autoit viruses



ps: character assassination is not allowed at this forum
02/18/2010 19:30 Ic3Frog#129
Thx for the BOT !!!
02/18/2010 20:37 KentuckyFC#130
schmuselord1 ich denke es ist zeit erwachsen zu werden und nicht zu beleidigen sollte ich es nötig haben viren hoch zu laden dann nur für dich via pm denn ich habe elitepvpers gern und möchte hier weiterhin mit diesem account bleiben sollteste weiterhin rufmord betreiben haste bald viele reports



edit: um dich nochmal richtig zu ownen [Only registered and activated users can see links. Click Here To Register...]

checke den bot mal das ist der selbe nur das ich den nochmal hochgeladen habe
02/18/2010 21:19 schmuselord1#131
du bist definitiv reported dafür. dein file hat mir nen virus gebracht, den ich sogar ausm bootsektor entfernen musste. ich hoffe du kriegst nen ban
02/18/2010 21:30 KentuckyFC#132
jetzt auch noch lügen erzählen deswegen haben den bot auch 17k von jt gedownloadet weil da ein virus drinne ist

schmuselord1 wahnsinn


Leute checkt einfach google nach den 4 viren die von autoit sind dann würde euch google oder einer von den scriptern das selbe sagen ich glaube sogar das der bot mit upx gepackt ist dann isses klar das der solche viren anzeigt

PS: viren bekommt man nicht aus dem boot sektor ausser mit formatieren ich hoffe du formatierst deinen pc das würde mich freuen
02/18/2010 22:31 Huseby#133
Quote:
Originally Posted by KentuckyFC View Post
You get owned by KentuckyFC

Its the original bot from JTremblay so stfu these are Autoit viruses



ps: character assassination is not allowed at this forum
Thats not how the autoit false virus scans looks like.
Also dont use inappropriate language.
02/19/2010 07:25 KentuckyFC#134
Quote:
Originally Posted by Huseby View Post
Thats not how the autoit false virus scans looks like.
Also dont use inappropriate language.

than delete jtremblays thread too o.0
if you think that there are viruses i checked this but the bot is not for epic6


Here the bot again with JT´s thread

[Only registered and activated users can see links. Click Here To Register...]
02/19/2010 08:00 Huseby#135
Quote:
Originally Posted by KentuckyFC View Post
than delete jtremblays thread too o.0
if you think that there are viruses i checked this but the bot is not for epic6


Here the bot again with JT´s thread

[Only registered and activated users can see links. Click Here To Register...]
Im not a mod here so i dont got any rights here at all.
But i have reported the post so im guessing the mods here will deal with it.