Harpydog Posted July 8, 2006 Share Posted July 8, 2006 Hey guys well i have been working on this bot on and off for a few weeks now and i jstu cant get it... the potions work.. but well.. my targeting is where it messes up... It targets the bear right.. it sends my guy to attack.. but where it goes wrong.. is like it repetedly tpyes /target grizzly bear... any help is MUCH appreciated... expandcollapse popup; ---------------------------------------------------------------------------- ; ; AutoIt Version: 3.1.0 ; Author: A.N.Other <myemail@nowhere.com> ; ; Script Function: ; Template AutoIt script. ; ; ---------------------------------------------------------------------------- ; Script Start - Add your code below here ;=========================== ; INitializing... HotKeySet("{ESC}", "CaptureESC") $Primary = "Left" Dim $Primary $secondary = "Right" Dim $secondary ;============================= ; Misc Func's... Func CaptureESC() Exit 0 EndFunc ;============================ ; Log In.... Run("C:\Program Files\Lineage II\system\l2.exe") WinWaitActive("Lineage II") sleep("10000") MouseClick($primary, 481, 331) Sleep("100") Send("Scyfer") Sleep("100") MouseClick($primary, 490, 355) Send("happy") sleep("100") MouseClick($primary, 461, 388) sleep("250") Mouseclick($primary, 505, 420) Sleep("1000") MouseClick($primary, 237, 493) sleep("200") MouseClick($primary, 512, 679) sleep("15000") ;================================ ; Initializing set up Mouseclick($secondary) MouseWheel("up", 75) ;======================== ; checker AdlibEnable("Checker") While 1 sleep("20") WEnd ;====================== Func Checker() CheckHealth() CheckMana() TargetGriz() EndFunc ;=============================== ; Health Checking... Func CheckHealth() $Color = Pixelgetcolor(130, 38) If $Color = 5379096 Then Send("{F8}") sleep("15000") EndIf EndFunc ;================================== ; Mana Check... Func CheckMana() $MColor = PixelGetcolor(58, 51) $Combat = PixelGetColor(7, 100) If $MColor = 1057866 AND $combatt <> 3221788 Then Send("{F12}") sleep("10000") Send("{F12}") sleep("100") EndIf EndFunc ;================================ ; Target Func TargetGriz() $targetloop = 0 If $targetloop = 0 Then Do Send("{ENTER}") Send("/target Grizzly Bear") sleep("150") Send("{ENTER}") $CombatIn = PixelGetColor(7, 100) Until $CombatIn = 3221788 If $combatIn = 3221788 Then $Targetloop = 1 Do Send("{f4}") sleep("4000") Send("{F4}") $Combatfinished = Pixelgetcolor(17, 100) Until $combatfinished = 6697224 EndIf If $combatfinished = 6697224 Then Send("{F5}") sleep("500") send("{F2}") sleep("500") send("{F2}") sleep("500") Send("{F2}") $targetloop = 0 EndIf EndIf EndFunc Link to comment Share on other sites More sharing options...
lopolop Posted July 8, 2006 Share Posted July 8, 2006 (edited) u check your color to make sure Until $CombatIn = 3221788 --> this # is correct? if it isn't then it will repeate and check 6697224 becuase if that is always correct it would check healt, mana, and target, continualy... Edited July 8, 2006 by lopolop Link to comment Share on other sites More sharing options...
Paulie Posted July 8, 2006 Share Posted July 8, 2006 Take the part of the code that sends the "/target grizzley bear" out of the Do/Until loop then it won't repeat it Link to comment Share on other sites More sharing options...
Harpydog Posted July 9, 2006 Author Share Posted July 9, 2006 But i want it to repeat.. well i want it to type it.. once the target box appears ($combatin) then to stop.. and send my char to attack.. then once $combatin does not equal the color.. to target a mob again --Harpy Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now