SellAllMyCrap.mac ?

Need some help with that macro you're working on or aren't quite sure how to get your macro to do something? Ask here!

Moderator: MacroQuest Developers

ImaNoob
a ghoul
a ghoul
Posts: 89
Joined: Mon Mar 08, 2004 4:37 am

SellAllMyCrap.mac ?

Post by ImaNoob » Sat Mar 20, 2004 7:03 am

I get lots of junk on all my characters, and I want to write a macro that sells everything I have that is sellable in inventory, in the shortest amount of time possible, so all I have to do is get near a merchant and target them, and run the macro.

Of course this is very dangerous (could accidently sell that UberSword of slashing +100 mana item my warrior) so I would probably need an ini file to mark items I want to keep.

Which brings up the question of how to start a macro like this?

As far as I can see, the following tasks would need to be done.

1 read ini file into an array of some sort.
2 Open merchant trade window
3 Loop through all bags and check for no-drop status, then load inventory items that are not no-drop into an array (Ideal option would be to check and make sure the merchant price is greater than 0 but I'm completely clueless on how to do something like that)
4 Seperate array into stackable and nonstackable items, then sort array
5 Sell non-stackable items to merchant 1 at a time
6 Sell stacks to merchant.
7 Close merchant window.

Am I missing something here? Do I have any general concepts wrong?
What commands would I use to accomplish any of these steps? Do any code snippets already accomplish any or all of these tasks? If so where are they located at?

Thank you in advance for your help!

rootmoth
orc pawn
orc pawn
Posts: 27
Joined: Fri Oct 04, 2002 9:27 pm

Post by rootmoth » Tue Mar 23, 2004 6:44 pm

Your outline looks solid. Here is where I would do it differently.

build a routine that selects each bag slot and does some stuff while it is selected. Within that routine, have it check for the item name and check it against your "keeper" list. You should be very certain that items you don't want sold are on the list or NEVER in your bags.

If not found, hold down the shift key and /click left mechant sell. that doesnt care if its stackable or not, and will sell however many there are in that packslot.

If the item is nodrop, or cannot be sold, it will simply not sell it. You will have to deal with those manually.

User avatar
Bad Karma
a snow griffon
a snow griffon
Posts: 346
Joined: Sat Nov 22, 2003 9:34 pm
Contact:

Re: SellAllMyCrap.mac ?

Post by Bad Karma » Sat Mar 27, 2004 7:38 am

ImaNoob wrote:What commands would I use to accomplish any of these steps?
Here is a list of commands: http://macroquest2.com/main.php?p=manual

ImaNoob wrote:Do any code snippets already accomplish any or all of these tasks? If so where are they located at?
My guess would be...umm...in the Snippets forum, also found here.

rootmoth wrote:If the item is nodrop, or cannot be sold, it will simply not sell it. You will have to deal with those manually.
/if $cursor(nodrop)=TRUE /destroy or whatever...
[b]- Bad Karma
________________________________________[/b]

In our own quest for excellence, we should strive to take the time to help those who help themselves.

All others should [b]RTFM[/b]!!!!!!!!!