FARMPAD!

Got a cool macro idea? Wanna request a macro? Here is the place for you!

Moderator: MacroQuest Developers

do_know_a_little
RTFM, then ask again
Posts: 19
Joined: Thu Jun 26, 2003 1:26 pm

FARMPAD!

Post by do_know_a_little » Thu Jan 15, 2004 5:43 pm

I don't know what you have to do to convert the outdated to the current version but PLEASE FARMPAD was my life!

Here's what the original code was:

Code: Select all

| farmpad.mac 
| farm quality pelts and spiderling silk in EC 
| for making into leather padding 
#include routines.mac 

sub Main 
   /lootn never 
   /alert clear 1 
   /alert add 1 npc bear 
   /alert add 1 npc kodiak 
   /alert add 1 npc spiderling 
   /alert add 1 npc puma 
   /alert add 1 npc lion 
   /alert add 1 npc cat 
   /alert add 1 npc wolf 
   /press esc 

   :Start 
      /call findTarget 
      /varset v11 $target(id) 
      /call killTarget 
      /if n $target(id)==$char(id) /goto :Stop 
      /target corpse 
      /if n $target(id)==$v11 /call lootTarget 
   /goto :Start 

   :Stop 
   /attack off 
   /call autorun 0 
   /lootn always 
/return 

Sub findTarget 
   /target alert 1 nopcnear 60 
   /delay 2 
/return 

Sub killTarget 
   /varset v60 $target(id) 
   /if $v60==0 /return 
   /varset t0 2m 
   /varset v12 1 
   /varset v80 0 
   /face nopredict 

   :Follow 
      /if n $target(id)==$char(id) /return 
      /if "$target(id)"!="$v60" /goto :KillDone 
      /if "$target(name)"~~"corpse" /goto :KillDone 
      /face nopredict 
      /if n $target(distance)>12 /call autorun 1 
      /if n $target(distance)<15 { 
         /call autorun 0 
         /if $v12==1 { 
            /if n $target(id)==$char(id) /return 
            /call findTarget            |anti-ks code 

            /if "$target(id)"!="$v60" /goto :KillDone 
            /attack on 
            /varset v12 0 
         } 
      } 
      /if n $t0==0 /press esc 
      /varset v51 $char(x) 
      /varset v52 $char(y) 
      |/delay 1 
      /if n $v51==$char(x) /if $v52==$char(y) /call tree $v12 
   /goto :Follow 
    
   :KillDone 
   /sendkey up up 
   /attack off 
   /delay 3 
/return 

Sub Tree 
   /delay 3 
   /if $p0==0 /return 
   /sendkey up up 
   /sendkey down down 
   /delay 2 
   /sendkey up down 
   /sendkey down ctrl 
   /if n $rand(99)>50 { 
      /sendkey down right 
   } else { 
      /sendkey down left 
   } 
   /delay 3 
   /sendkey up right 
   /sendkey up left 
   /sendkey up ctrl 
   /varset v80 0 
/return 

Sub lootTarget 
   /delay 2 
   :gotocorpse 
   /if n $target(distance)>10 { 
      /face 
      /sendkey down up 
      /goto :gotocorpse 
   } 
   /sendkey up up 

   /face 
   /loot 
   /delay 10 
    
   /varset v10 0 
   :LootLoop 
      /click left corpse $v10 
      /delay 5 
      /if "$cursor(name)"=="NULL" /goto :LootDone 
      /if "$cursor(name)"~~"silk" { 
         /click left auto 
      } else /if "$cursor(name)"~~"quality" { 
         /click left auto 
      } else { 
         /click left destroy 
         /delay 1 
         /click left 458 420 
         /delay 1 
      } 
      /varadd v10 1 
   /goto :LootLoop 
    
   :LootDone 
   /delay 3 
   /press esc 
   /delay 2 
/return 
I love you guys.

wrangler
a ghoul
a ghoul
Posts: 93
Joined: Fri Nov 28, 2003 3:07 pm

Post by wrangler » Thu Jan 15, 2004 7:21 pm

the hunter.mac one works well for this

http://macroquest2.com/phpBB2/viewtopic.php?t=3240