buy food/drink mac?

lostsk8r

New member
Joined
Jul 25, 2006
Messages
97
Reaction score
0
Points
0
I'm looking for a macro that will open the targetted merchant's goods, find iron rations and water flask, buy 2 stacks of iron rations and 4 stacks of water. The idea is that I can broadcast via isboxer to target a merchant then broadcast /mac buyfooddrink

So tired of summoning food/drink manually and buying food/drink manually :p but i hate having low mana regen.
 
Modified the alcohol tolerance macro to make my own. Have to set the merchant name in the code and the amount of food/drink (and name of it). I might try to make it just use the targetted merchant as the merchant name but havent figured that out yet.

Also need buy.inc in the macros folder.

Code:
#include common/buy.inc


Sub Main
	
        /declare MerchantName string outer
        /declare Food string outer
	/declare Drink string outer

| ***********************************************
| *   Change these settings if you want.        *
| ***********************************************

        /varset MerchantName "Bubar"
        /varset Food "Iron Ration"
	/varset Drink "Water Flask"
 


| ***********************************************
| Buy Food                                    *
| ***********************************************

	/target ${MerchantName}
	/face
	/delay 1s
	/click right target
	/delay 1s
	/call Buy ${Food} 60
	/call Buy ${Drink} 120
	/keypress esc
	/echo Food and Drink complete.
	/endmacro
/return
 
I dunno I roughly estimated that iron rations lasts twice as long as water :p and iron rations because less trips to the merchant since I box a lot of characters.
 
Why not just buy the food and drink summon items from marketplace and never buy food again..I have them on all toons and have a dowbshit that keeps them all in food/ drink
 
the super spicy curry and freezing cold ice cream? ill check it out, im on TLP
 
Why not let your characters starve for years? Mine have only eaten during times where I had eatable/drinkable quest items to handle :p
 
Ya, didn't they take out the stamina (or end) hits years ago, so other than annoying you with out of food/drink and hungry/thirsty messages, it has no effect?

If that's the case, then can just enable the NoFoodorDrinkMessages docrack, and not bother.

IOW, if that's the only reason (messages), then enable that.

If it has some other effect, then forget I said it. :)

Of course, if you prefer/use stat food/drink, then that's different, but you ain't buying that from the vendor (i.e., rations/iron rations/muffins/etc. or water flasks).

htw
 
Having no food/drink effects my mana regeneration according to my stats tab on TLP. I tested regen with clarity/nofooddrink and clarity/fooddrink.
 
Having no food/drink effects my mana regeneration according to my stats tab on TLP. I tested regen with clarity/nofooddrink and clarity/fooddrink.
Thanks, good to know (for people playing!). :)

htw
 
I use stat foods on all my toons and have been going through the hassle of buy miraculous foods/drinks so I don't gotta restock all my toons as much. Total pain in the ass. Sometimes I run out of regular foods/drinks and my boxes start eating drink the stuff that are 900pp per food. This mac is perfect, thanks a lot lostSK. I took out /face because it was causing all my boxes to look up, added in /stick 15 so they all run to within range to use the merchant, a couple more /keypress esc so every window is closed up when they are done buying and /stick off. Pretty neat, I just /bca //mac buyfood and all my bots buy a 100 each of food/drink. I use to do that one by one manually lol
 
I use stat foods on all my toons and have been going through the hassle of buy miraculous foods/drinks so I don't gotta restock all my toons as much. Total pain in the ass. Sometimes I run out of regular foods/drinks and my boxes start eating drink the stuff that are 900pp per food. This mac is perfect, thanks a lot lostSK. I took out /face because it was causing all my boxes to look up, added in /stick 15 so they all run to within range to use the merchant, a couple more /keypress esc so every window is closed up when they are done buying and /stick off. Pretty neat, I just /bca //mac buyfood and all my bots buy a 100 each of food/drink. I use to do that one by one manually lol

Willing to post your edited code? This sound super useful.
I've got the one posted working, but I'm not confident enough to start trying to add stuff to the code.


*EDIT*
Nm I guess it's pretty simple.
 
Last edited:
Ya, was pretty easy to change. I havent a clue about programing, but this was pretty much english to change what I changed.
 
So is there a way to change the stack value? I am trying to buy things at 100 in a stack and it is only buying 20, dont see anything in the code
 
Try buying a stack manually from the vendor by using Shift when clicking the purchase button, and see if it only gives 20. Some items, tho they stack beyond 20, only buy stacks of 20 at a time from vendors when using Shift key + button.
 
I’m unable to try at the moment, but I know regular buying defaults it to 100 in the stack.
 
Confirmed it buys in stack of 100 if you shift click but the macro only buys in 20, tried changing everything I could find in common.inc and couldn’t get it to change
 
I would suspect there's something in buy.inc that looks at how many are left to buy. If it's less than 20, it buys a stack of the quantity less than 20, else it buys 20.

I'm unable to look at it atm, but if I get a chance later and remember, I'll try to see if I can find it.