Register for your free account! | Forgot your password?

You last visited: Today at 17:16

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

 

[Suche] Speziélen Fishingbot

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Jul 2005
Posts: 104
Received Thanks: 1
ICh hab die searchfunktion schon benutzt :P

ich hatte vor langer zeit nen autoit fishingbot

der nicht nach bobbercolor gescannt hat sondern

nach mouseover tooltip denn goldenen namen "Blinker" gesucht hat

wer die rarität hat gimme :P



Rapi is offline  
Old   #2
 
elite*gold: 0
Join Date: Jul 2005
Posts: 104
Received Thanks: 1
habs selber auf pladde gefunden

Code:
; ******************************************************************************************************** 
; FishBOT by Me242 - adapted from Foobie script which was adapted from Pantless Krab's example 
; Version 1.2 

; Globals 
$title = "WoW FishBOT" 

; Title of game window. 
$win_title = "WORLD OF WARCRAFT" 

$top_border_height = 23 
$left_border_width = 4 

; How many pixels to move to the right each time. 
$move_left = 10 

; How many pixels to move down for each run. 
$move_down = 25 

; Pixels to move back LEFT when bobber is found. 
; Note, if the cursor moves TOO far to the left when found, lower this value and vice versa. 
$found_move_left = 10 

; Pixels to move DOWN when bobber is found. 
; Note, if the cursor moves TOO far down when found, lower this value and vice versa. 
$found_move_down = 5 

; Button to hit for fishing skill. 
$fishing_pole = 1 

; Set to 0 if you do NOT use the QuickLoot addon from 
; http://www.curse-gaming.com/mod.php?addid=132 
; If you ARE using quickloot, set it to 1 
$using_quickloot = 1 

; Your resolution. Only 1024x786 & 800x600 supported with without personal modification. 
$screen_width = 1024 
$screen_height = 768 

; Waiting time between throws. 
$time_to_wait = 30050 

; Display what its doing in traytips.. useful for debugging and/or fun. 1 = on, 0 = off 
$traytips = 1 

dim $start_time 

; ******************************************************************************************************** 
; Hot Keys 
HotKeySet("{PAUSE}", "request_end") 

; ******************************************************************************************************** 
if not WinExists($win_title, "") then 
  msg($win_title & " window must be open.") 
  Exit 
endif 

WinActivate($win_title, "") 
WinSetOnTop($win_title, "", 0) 
Sleep(500) 

check_window() 

;AutoItSetOption ( "PixelCoordMode", 0 ) 

$win_pos = WinGetPos($win_title, "") 
$win_x = $win_pos[0] + $left_border_width 
$win_y = $win_pos[1] + $top_border_height 

$top = $win_y + (.25 * $screen_height) 
$bottom = $top + (.35 * $screen_height) - 1 
$left = $win_x + (.15 * $screen_width) 
$right = $left + $screen_width - (.15 * 2.0 * $screen_width) - 1 

; Here we set the values for the different resolutions. 
; I've added a dummy one in the last 'elseif' you can play with 
; if you need to, without damaging the default ones. 
; If you run 1024 x 768 or 800 x 600, you should not need to modify this. 

; For 1024x768 
if $screen_width = 1024 and $screen_height = 768 then 

 &#59; Cordinates to look for the yellow "Fishing Bobber" text. 
 $bobber_text_location_x1 = 620 
 $bobber_text_location_x2 = 645 
 $bobber_text_location_y1 = 78 
 $bobber_text_location_y2 = 80 

 &#59; Only used if $quickloot is 0 ! 2 locations it will left click on when looting. 

 &#59; First location coordinates. 
 $no_quickloot_1_x = 45 
 $no_quickloot_1_y = 274 

 &#59; Second location coordinates. 
 $no_quickloot_2_x = 45 
 $no_quickloot_2_y = 222 

; For 800x600 
elseif $screen_width = 800 and $screen_height = 600 then 
 $bobber_text_location_x1 = 705 
 $bobber_text_location_x2 = 707 
 $bobber_text_location_y1 = 557 
 $bobber_text_location_y2 = 570 
 $no_quickloot_1_x = 35 
 $no_quickloot_1_y = 213 
 $no_quickloot_2_x = 35 
 $no_quickloot_2_y = 180 

; Dummy. Play here if neeed. 
elseif $screen_width = 0000 and $screen_height = 0000 
 $bobber_text_location_x1 = 000 
 $bobber_text_location_x2 = 000 
 $bobber_text_location_y1 = 000 
 $bobber_text_location_y2 = 000 

 $no_quickloot_1_x = 00 
 $no_quickloot_1_y = 00 
 $no_quickloot_2_x = 00 
 $no_quickloot_2_y = 00 
else 
 MsgBox(0, "Resolution Error", "Only 1024x768 and 800x600 are supported without personal modification") 
 Exit 
endif 

; Show a visual confirmation by making the mouse draw the area on the screen 
; that will be used to scan for the bobber. 
traytp("Drawing search area") 
MouseMove($left, $top, 0) 
MouseMove($right, $top, 10) 
MouseMove($right, $bottom, 10) 
MouseMove($left, $bottom, 10) 
MouseMove($left, $top, 10) 

cast_pole() 
find_float() 

; ******************************************************************************************************** 
func find_float() 

  while 1 
    &#59; Reset the $pos back to 0. 
    $pos = 0 
    if TimerDiff($start_time) >= $time_to_wait then 
      traytp("Resting.. waited long enough") 
      cast_pole() 
    endif 
    sleep(30) 
    &#59; Move cursor to starting position. 
    MouseMove($top, $left, 1) 
    &#59; Get its location. Put it in $mousepos_left_next and $mousepos_top_next since those needs to be set 
    &#59; for the first run. 
    $mousepos = MouseGetPos() 
    $mousepos_left_next = $left 
    $mousepos_top_next = $top 

    &#59; Loop this until we found the bobber ($pos isnt 0 when found). 
    while $pos = 0 
     &#59; Run the move_left function that moves the mouse to the right and looks for it. 
     $pos = move_left($mousepos_left_next, $mousepos_top_next, $top) 
     &#59; If $pos isnt 0, we found the bobber. 
     if $pos <> 0 then 
      &#59; Get current cursor position 
      $pos = MouseGetPos() 
      &#59; Calculate the positions to move the cursor back to. 
      $move_left_to = $pos[0] - $found_move_left 
      $move_top_to = $pos[1] + $found_move_down 
      &#59; Move the cursor back the number of pixels. 
      MouseMove($move_left_to, $move_top_to, 0) 
      &#59; We should be close to the bobber now. Start looking for the splash at these coords. 
      traytp("Found bobber at x:" & $move_left_to & " y:" & $move_top_to & " - Waiting for splash") 
      find_splash($move_left_to, $move_top_to) 
     endif 

     &#59; Bobber wasnt found. Move down the number of defined pixels. 
     $mousepos_top_next = $mousepos_top_next + $move_down 

     &#59; Check if were at the bottom right border. Bobber wasnt found if so. Restart from beginning. 
     if $mousepos_left_next <= $right then 
      if $mousepos_top_next >= $bottom then 
        $start_time = $time_to_wait 
        exitloop 
      endif 
     endif 
     &#59; Relax a little. 
     Sleep(20) 

    wend 
    &#59; Relax a little. 
    Sleep(10) 
  wend 
endfunc 

; Function to move the mouse to the right and looking for the bobber color. 
func move_left($mousepos_left_next, $mousepos_top_next, $top) 
    traytp("Looking for bobber, at x:" & $mousepos_left_next & " to x:" & $right & " at y:" & $mousepos_top_next) 
    &#59; Loop until we found the right border. 
    while $mousepos_left_next <= $right 

     &#59; Search for the bobber text using high tolerance (50) since its still fading in. 
     $pos = PixelSearch($bobber_text_location_x1, $bobber_text_location_y1, $bobber_text_location_x2, $bobber_text_location_y2, 0xFFD200, 50, 1) 
     if @error then 
       &#59; Not found. Keep going. 
       SetError(0) 
     else 
      &#59; Found it ! Wait a second to allow it to fade in. 
       traytp("Looks promising at: x:" & $pos[0] & " y:" & $pos[1] & " - examine location.") 
       sleep(1000) 
      &#59; Search for the bobber text again using less tolerance (5). 
       $pos = PixelSearch($bobber_text_location_x1, $bobber_text_location_y1, $bobber_text_location_x2, $bobber_text_location_y2, 0xFFD200, 5, 1) 
       if @error then 
        &#59; Hm, not here. Keep looking. False alarm from first search. 
        SetError(0) 
       else 
       &#59; Found the bobber. Return its position 
        traytp("Found ""Fishing Bobber"" text at: x:" & $pos[0] & " y:" & $pos[1]) 
        return $pos 
       endif 
     endif 
     &#59; Calculate where to move the mouse to next. 
     $mousepos_left_next = $mousepos_left_next + $move_left 
     &#59; Move the cursor to the right, using aboves coordinates. 
     MouseMove($mousepos_left_next, $mousepos_top_next, 0) 
    wend 
    &#59; Nada found. Return $pos 0 so it moves down a bit and restarts the search. 
    return 0 
endfunc 

; ******************************************************************************************************** 
func find_splash($float_x, $float_y) 
  $search_left = $float_x - 32 
  $search_right = $search_left + 62 
  $search_top = $float_y - 32 
  $search_bottom = $search_top + 64 

  &#59; Usually you do not have to modify the search color for the splash, as the pixels 
  &#59; have a very distinctive, bright color. 
  $splash_color = 0xF6F6F6 

  &#59; Sometimes 30 tolerance works well, sometimes 20 is better in lit areas to avoid catching highlights 
  &#59; in other things. 
  $splash_tolerance = 20 
  
  &#59; The search step can be pretty small here (1 to 3) without worries because the search area is 
  &#59; so small once it has been narrowed down - speed isn't much of an issue. 
  $splash_search_step = 2 

  &#59; Search for splash 
  while TimerDiff($start_time) < $time_to_wait 
    $pos = PixelSearch($search_left, $search_top, $search_right, $search_bottom, $splash_color, $splash_tolerance, $splash_search_step) 
    if @error then 
      SetError(0) 
    else 
      &#59; Click on the splash 
      traytp("Got splash at x:" & $pos[0] & " y:" & $pos[1] & " - Loot it.") 
      MouseClick("right", $pos[0], $pos[1], 1, 2) 

      if $using_quickloot = 0 then 
       MouseMove($no_quickloot_1_x, $no_quickloot_1_y, 0) 
       traytp("Looting at x:" & $no_quickloot_1_x & " y:" & $no_quickloot_1_y & " in 3 seconds") 
       Sleep(3000) 
       MouseClick("left", $no_quickloot_1_x, $no_quickloot_1_y, 2, 2) 
       traytp("Looting at x:" & $no_quickloot_2_x & " y:" & $no_quickloot_2_y & " soon") 
       Sleep(200) 
       MouseMove($no_quickloot_2_x, $no_quickloot_2_y, 0) 
       Sleep(200) 
       MouseClick("left", $no_quickloot_2_x, $no_quickloot_2_y, 1, 2) 
      else 
       traytp("Looting at x:" & $pos[0] & " y:" & $pos[1] & " in 3 seconds") 
       Sleep(3000) 
       MouseClick("left", $pos[0], $pos[1], 1, 2) 
       traytp("Looting again just in case, at x:" & $pos[0] & " y:" & $pos[1] & " in 0.9 seconds") 
       Sleep(900) 
       MouseClick("left", $pos[0], $pos[1], 1, 2) 
      endif 

      Sleep(1100) 
      MouseMove($left, $bottom, 2) 
      
      ExitLoop 
    endif 
    Sleep(10) 
  wend 
  
  &#59; Cast pole and start all over again. 
  cast_pole() 
endfunc 

; ******************************************************************************************************** 
func cast_pole() 
  $start_time = TimerInit() 
  traytp("Pressing " & $fishing_pole & " to cast pole") 
  Send($fishing_pole) 
  Sleep(1000) 
endfunc 

; ******************************************************************************************************** 
func check_window() 
  $dimensions = WinGetClientSize($win_title, "") 
  if $dimensions[0] <> $screen_width or $dimensions[1] <> $screen_height then 
    msg("Invalid window size. You must use " & $screen_width & "x" & $screen_height & " resolution in window mode.") 
    Exit 
  endif 
endfunc 

; ******************************************************************************************************** 
func msg($text) 
  MsgBox(0, $title, $text) 
endfunc 

func traytp($text) 
  if $traytips = 1 then 
   TrayTip ($title, $text, 3, 16) 
  endif 
endfunc 

; ******************************************************************************************************** 
func request_end() 
  $MB_YESNO = 4 
  $MB_YES = 6 
  
  if MsgBox($MB_YESNO, $title, "End script?") == $MB_YES then 
    Exit 
  endif 
endfunc 

; ******************************************************************************************************** 
func drain_timer() 
  Msg("Restart") 
  $start_time = $start_time - $time_to_wait 
endfunc 

; ********************************************************************************************************


Rapi is offline  
Reply



« Previous Thread | Next Thread »

Similar Threads
gibt es LvL-Bot mit spezielen Update
gibts nen Lvl Bot der so sit das ich ich Metin im hintergrund lass und z.B en Film anguck oda sowas in der art^-^?
21 Replies - Metin2 Main - Discussions / Questions
Fishingbot + Bot
Visit out the Website LOTROBot by BotXpert :-) Have Fun!
2 Replies - LotRO Exploits, Hacks, Tools & Macros
Suche ein nostale fishingbot für pc mit 256 mbram^^
hey leute ich habe auf der seite schöne sachen gefunden wie z.B nostale angel boot aber es gibt da sehr ville probleme^^ mit autoit kann ich nix...
1 Replies - Nostale
Fishingbot
I have a problem :| . I download all three fishingbots from this forum and 2 don't work. Bot fishing_beta_0.1.i work when i press end but only one...
1 Replies - Metin2 Main - Discussions / Questions



All times are GMT +1. The time now is 17:16.


Powered by vBulletin®
Copyright ©2000 - 2016, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.

Support | Contact Us | FAQ | Advertising | Privacy Policy
Copyright ©2016 elitepvpers All Rights Reserved.