Powerarrows.mac The original. Use powerarrows2

Macro depository for macros written before the user variable changes that broke all of them.

Moderator: MacroQuest Developers

macrotoon
a ghoul
a ghoul
Posts: 106
Joined: Wed Sep 18, 2002 4:38 pm

Powerarrows.mac The original. Use powerarrows2

Post by macrotoon » Wed Nov 13, 2002 12:55 am

This is old code that no longer works. There is another code released by Zxeses

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





I used the vendor in SH to get my dwarf cleric with bad faction and low charisma from 0 to 167 fletching in around 45 minutes with this code.

Its a little old, and hasnt been tested in a month or so. It was written before the great price nerf happened.

If you still desire to get fletching skills up. This should take you to 202 in a couple hours.

What this does is buys and combines and sells in batches of 20, then checks for skill and does it over.

I would suggest putting some delays in there. As well as not doing it while afk. Dont macro afk it only hurts us all. Hell i havnt macro'd in a while since they warned us about it. Kinda scared to. When you have 3 characters over 60 you dont wanna loose that much time invested on something as trivial as this.


EDIT******Added a skill check when making CeramicVanes arrows. If the skill is 199 or more it will end the macro to keep you from skilling past the point of no return.

Good luck.

Code: Select all

|  POWERARROWS.MAC 
| 
| 
| 
| 

#include routines.mac 
#turbo 

Sub Main 
      /if "$invpanel"!="TRUE" /press i 
        /call FindCombiner Fletching 
         /if $return==99 /return 
      /varset v80 $return 
      /call cleanpack $v80 
      /click left inv $v80 
      /click left inv 0 
      /click left auto 
      /click right inv $v80
      /target arrowsmith 
      /face 
   :WaitMerchant 
      /press u 
      /if $merchant()==FALSE /goto :WaitMerchant 

:SkillCheck 
/skill Fletch 
/varset v1 $char(skill,"fletching") 
/if n $v1<30 /call MedGroveNock 
/if n $v1<65 /if n $v1>=30 /call BoneShaft 
/if n $v1<100 /if n $v1>=65 /call HookedArrowHead 
/if n $v1<130 /if n $v1>=100 /call CeramicShaft 
/if n $v1<160 /if n $v1>=130 /call BoneVanes 
/if n $v1<199 /if n $v1>=160 /call CeramicVanes 
/if n $v1>=199 {
/echo Your skill cannot be increased more than 199 with this script If you wish to raise skill higher you can change the script to do so.  
/cleanup
/endmacro 
}
/goto :SkillCheck 

Sub MedGroveNock 
      /for v2 1 to 20 
      /click left merchant up 
      /click left merchant up 
      /click left merchant up    
      /delay 5 
      | ------"field point" 
      /click left merchant 0 
      /call BuyItemSingle 
      | ------ "wooden arrow shaft" 
      /click left merchant 3 
      /call BuyItemSingle 
      | ---------- "round cut" 
      /click left merchant 7 
      /call BuyItemSingle 
      | -------Medium Groove Nock-------- 
      /click left merchant down 
      /click left merchant down 
      /click left merchant down 
      /click left merchant 9 
      /call BuyItemSingle 
      /call MakeArrows 
      /call SellItem class 
      /next v2 
      /return 

Sub BoneShaft 
      /for v2 1 to 20 
/click left merchant up 
      /click left merchant up 
      /click left merchant up    
      | ------"field point" 
      /click left merchant 0 
      /call BuyItemSingle 
      | ---------- "bone arrow shaft" 
      /click left merchant 4 
      /call BuyItemSingle 
      | ---------- "round cut" 
      /click left merchant 7 
      /call BuyItemSingle 
      | -------Large Groove Nock-------- 
      /click left merchant down 
      /click left merchant down 
      /click left merchant down 
      /click left merchant 8 
      /call BuyItemSingle 
      /call MakeArrows 
      /call SellItem class 
      /next v2 
      /return 

Sub HookedArrowHead 
      /for v2 1 to 20 
/click left merchant up 
      /click left merchant up 
      /click left merchant up    
      | ------"Hooked Arrow Head" 
      /click left merchant 1 
      /call BuyItemSingle 
      | ---------- "Wooden arrow shaft" 
      /click left merchant 3 
      /call BuyItemSingle 
      | ---------- "round cut" 
      /click left merchant 7 
      /call BuyItemSingle 
      | -------Large Groove Nock-------- 
      /click left merchant down 
      /click left merchant down 
      /click left merchant down 
      /click left merchant 8 
      /call BuyItemSingle 
      /call MakeArrows 
      /call SellItem class 
      /next v2 
      /return 

Sub CeramicShaft 
      /for v2 1 to 20 
/click left merchant up 
      /click left merchant up 
      /click left merchant up    
      | ------"Field Arrow Head" 
      /click left merchant 0 
      /call BuyItemSingle 
      | ---------- "Ceramic arrow shaft" 
      /click left merchant 5 
      /call BuyItemSingle 
      | ---------- "round cut" 
      /click left merchant 7 
      /call BuyItemSingle 
      | -------Large Groove Nock-------- 
      /click left merchant down 
      /click left merchant down 
      /click left merchant down 
      /click left merchant 8 
      /call BuyItemSingle 
      /call MakeArrows 
      /call SellItem class 
      /next v2 
      /return 

Sub BoneVanes 
      /for v2 1 to 20 
/click left merchant up 
      /click left merchant up 
      /click left merchant up    
      | ------"Field Arrow Head" 
      /click left merchant 0 
      /call BuyItemSingle 
      | ---------- "Wooden arrow shaft" 
      /click left merchant 3 
      /call BuyItemSingle 
      | ---------- "Set of Bone Arrow Vanes" 
      /click left merchant 11 
      /call BuyItemSingle 
      | -------Large Groove Nock-------- 
      /click left merchant down 
      /click left merchant down 
      /click left merchant down 
      /click left merchant 8 
      /call BuyItemSingle 
      /call MakeArrows 
      /call SellItem class 
      /next v2 
      /return 

Sub CeramicVanes 
      /for v2 1 to 20 
      /if n $v1>=199 /return
/click left merchant up 
      /click left merchant up 
      /click left merchant up    
      | ------"Field Arrow Head" 
      /click left merchant 0 
      /call BuyItemSingle 
      | ---------- "Wooden arrow shaft" 
      /click left merchant 3 
      /call BuyItemSingle 
      | ---------- "Set of Ceramic Arrow Vanes" 
      /click left merchant down 
      /click left merchant 10 
      /call BuyItemSingle 
      | -------Large Groove Nock-------- 
      /click left merchant down 
      /click left merchant down 
      /click left merchant 8 
      /call BuyItemSingle 
      /call MakeArrows 
      /call SellItem class 
      /next v2 
      /return 

Sub MakeArrows 
         /if $pack($v80,closed)==TRUE /click right inv $v80 
      :MakeArrows 
         /click left auto 
         /click left pack $v80 combine 
      :WaitArrows 
         /delay 0 
         /if $pack($v80,empty)==FALSE /goto :WaitArrows 
      /delay 1 
      :waitdrop 
         /click left auto 
      /if $cursor()==TRUE /goto :waitdrop 
      /return 

Sub BuyitemSingle 
    /sendkey down ctrl 
        /varset t1 10 
        /varcalc p2 $char(plat)*1000+$char(gold)*100+$char(silver)*10+$char(copper) 
       /click left merchant buy 
      :BuyItemLoop 
          /delay 1 
      /if n $t1<1 /click left auto 
     /if n $t1<1 /click left merchant buy 
      /if n $calc($char(plat)*1000+$char(gold)*100+$char(silver)*10+$char(copper)==$p2 /goto :BuyItemsLoop 
   /sendkey up ctrl 
/return 
added buyitemsingle to the main code
Last edited by macrotoon on Tue Aug 12, 2003 1:09 am, edited 9 times in total.

macrotoon
a ghoul
a ghoul
Posts: 106
Joined: Wed Sep 18, 2002 4:38 pm

Post by macrotoon » Wed Nov 13, 2002 1:00 am

Forgot to add. You have to have the fletching kit in the first inventory slot to make it work correctly. I know this is not the common spot, but do it anyways.

aGuy
orc pawn
orc pawn
Posts: 18
Joined: Tue Nov 05, 2002 3:22 pm

Post by aGuy » Wed Nov 13, 2002 8:31 am

I see that you are dropping the made arrows into the auto area.

If you have your fleching kit in the first inventory, wont the made arrows get dropped into the fletching kit?

macrotoon
a ghoul
a ghoul
Posts: 106
Joined: Wed Sep 18, 2002 4:38 pm

Post by macrotoon » Wed Nov 13, 2002 9:01 am

YEP

aGuy
orc pawn
orc pawn
Posts: 18
Joined: Tue Nov 05, 2002 3:22 pm

Post by aGuy » Wed Nov 13, 2002 9:58 am

So is it this line that takes care of this?

Code: Select all

/call cleanpack $v80

macrotoon
a ghoul
a ghoul
Posts: 106
Joined: Wed Sep 18, 2002 4:38 pm

Post by macrotoon » Wed Nov 13, 2002 12:34 pm

Nope.
Its this line

Code: Select all

/call SellItem class 

aGuy
orc pawn
orc pawn
Posts: 18
Joined: Tue Nov 05, 2002 3:22 pm

Post by aGuy » Wed Nov 13, 2002 12:46 pm

I do not understand the logic here.

This is my understaning from looking at this script.

Once I combine items to make a stack of arrows, I then drop what is on my cursor into the auto area. This then will drop the arrows into my fletching kit because it is in the first inventory slot. I then must sell this stack of arrows before I do another combine.

Is this correct?

macrotoon
a ghoul
a ghoul
Posts: 106
Joined: Wed Sep 18, 2002 4:38 pm

Post by macrotoon » Wed Nov 13, 2002 2:18 pm

It doesnt buy a stack of the items. It only buys one at a time.
I forgot I had added this to my routines.mac

Code: Select all

Sub BuyitemSingle
    /sendkey down ctrl
        /varset t1 10
        /varcalc p2 $char(plat)*1000+$char(gold)*100+$char(silver)*10+$char(copper)
       /click left merchant buy
      :BuyItemLoop
          /delay 1
      /if n $t1<1 /click left auto
     /if n $t1<1 /click left merchant buy
      /if n $calc($char(plat)*1000+$char(gold)*100+$char(silver)*10+$char(copper)==$p2 /goto :BuyItemsLoop
   /sendkey up ctrl
/return
The way the code works it doesnt spam the players around the merchant. it opens merchant then does everyting. there is no reason to buy the items in stacks when doing this.

order of operation

open merchant
check skill
----buy components
makes arrows
sells arrows
----goes back to buy components. 20 times
--goes back to check skill after doing components 20 times

You could of course check the skill every single combine if you likes. Just take out the for next loop in the particular set of components. I would put an echo in there for when it goes to the next set though.

macrotoon
a ghoul
a ghoul
Posts: 106
Joined: Wed Sep 18, 2002 4:38 pm

Post by macrotoon » Fri Nov 15, 2002 11:43 pm

Just curious. With 200+views if anyone have tried this, and what you think.

Valerian
a grimling bloodguard
a grimling bloodguard
Posts: 709
Joined: Sun Jul 28, 2002 3:29 am

Post by Valerian » Sat Nov 16, 2002 2:15 am

aye, works great, love it, except on the first type of combine it's still got a couple debugging echos in, but that's easy enough to take out... also had to modify it slightly to ensure that it would open the fletching kit before trying to press the combine button... other than that, excellent.

User avatar
rizwank
Huggle Police
Huggle Police
Posts: 524
Joined: Tue Jul 23, 2002 12:07 am
Contact:

Post by rizwank » Sat Nov 16, 2002 4:47 am

you know whats lovely..

I just can breeze through this post and smile and not have to delete it and hunt down the person who wrote it... you have to be thankful for teh c6 nerf in some way...

macro away!
#macroquest op
Macroquest Official Documentarion
Macroquest Board Moderator
All around cool guy

[img]http://medicomuerte.users.btopenworld.com/images/fairy_bounce08.gif[/img]

Dirtface
a lesser mummy
a lesser mummy
Posts: 39
Joined: Tue Nov 12, 2002 2:43 am

Post by Dirtface » Sat Nov 16, 2002 5:56 am

This didnt work for me at all. It just kept buying and buying and buying.

Valerian
a grimling bloodguard
a grimling bloodguard
Posts: 709
Joined: Sun Jul 28, 2002 3:29 am

Post by Valerian » Sat Nov 16, 2002 1:10 pm

like I said in my post, you have to include something to make sure it'll open the fletching kit. change

Code: Select all

      /click left inv $v80 
      /click left inv 0 
      /click left auto
to

Code: Select all

      /click left inv $v80 
      /click left inv 0 
      /click left auto 
      /click right inv $v80

macrotoon
a ghoul
a ghoul
Posts: 106
Joined: Wed Sep 18, 2002 4:38 pm

Post by macrotoon » Mon Nov 18, 2002 1:52 am

Glad your getting some use from it Val.

Seems i left some echo's in there. I put echo's in sometimes to debug. To see how far the macro gets before it acts funny.

Thanks for the change. Didnt realize i didnt have the kit open.

Enjoy

Memphis
decaying skeleton
decaying skeleton
Posts: 1
Joined: Mon Nov 18, 2002 4:10 am
Location: none
Contact:

Any ideas ??

Post by Memphis » Mon Nov 18, 2002 4:13 am

I tried this macro tonight and all it did was kick me to desktop. Any ideas, yes im a bit new could just be me.