EZ Server

General Category => Quest and Guides => Topic started by: Dimur on February 04, 2019, 11:25:01 am



Title: Sell hotkey
Post by: Dimur on February 04, 2019, 11:25:01 am
This hotkey is probably useless to most people since almost anything worth looting to sell to vendors is already set to stackable, but for people farming zones that drop a lot of expensive blue diamonds, this is a single hotkey press for selecting an item from inventory and selling it to a vendor.

Line 1: /if (${FindItem[expensive blue diamond].ID}) /itemnotify ${FindItem[expensive blue diamond].InvSlot} leftmouseup
Line 2: /if (${SelectedItem.ID} == 130199) /notify MerchantWnd MW_Sell_Button leftmouseup

This can be modified for selling stacks of items if you really want, but all I needed was to make selling expensive blue diamonds scattered across my bag slots less tedious.


Title: Re: Sell hotkey
Post by: Natedog on February 04, 2019, 01:50:42 pm
If you wanna go even crazier there is a way to sell everything from an INI file :D

First run generates an INI file in the MQ2 folder of all the items in your inventory .. open it and change the ones listed as VALUED to SELL if you want them to be sold next time you run the macro.. :)

Takes a bit of time to get every item into the INI file over time.. but worth it once its filled

heres my filled one from ages ago :D

https://pastebin.com/RqsYx8CD

it must be named "EZ (Linux) x4 Exp_natesell.ini"


Vendor window needs to be open to run it as well.. so thats a thing :D.. just click vendor and start selling all your junk lol

Code:
#turbo

Sub Main
/call SETUPLOOT
/call PackSell
/return


sub SETUPLOOT
/if (!${Ini[${MacroQuest.Server}_natesell.ini,Setup,Version]}) /call LoadLoot
/return

sub LoadLoot
/ini "${MacroQuest.Server}_natesell.ini" "Setup" "Version" "1"
/ini "${MacroQuest.Server}_natesell.ini" "A" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "B" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "C" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "D" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "E" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "F" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "G" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "H" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "I" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "J" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "K" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "L" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "M" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "N" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "O" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "P" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "Q" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "R" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "S" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "T" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "U" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "V" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "W" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "X" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "Y" "1" "1"
/ini "${MacroQuest.Server}_natesell.ini" "Z" "1" "1"
/return


sub PackSell
/if (${Window[MerchantWnd].Open}) {
/declare packnum int local
/declare T int local

/for packnum 1 to 8
/if (!${Window[pack${packnum}].Open} && ${InvSlot[pack${packnum}].Item.Container}) {
/itemnotify pack${packnum} rightmouseup
/delay 6
}
/if (${Window[pack${packnum}].Open} && ${InvSlot[pack${packnum}].Item.Container}) {
/for T 1 to 10
/if (${Ini[${MacroQuest.Server}_natesell.ini,${InvSlot[pack${packnum}].Item.Item[${T}].Name.Left[1]},${InvSlot[pack${packnum}].Item.Item[${T}].Name}].Length}) { 
/if (${Ini[${MacroQuest.Server}_natesell.ini,${InvSlot[pack${packnum}].Item.Item[${T}].Name.Left[1]},${InvSlot[pack${packnum}].Item.Item[${T}].Name}].Equal[SELL]}) {
/itemnotify in pack${packnum} ${T} leftmouseup
/delay 9
/shiftkey /notify MerchantWnd MW_Sell_Button leftmouseup
/delay 9
}
} else {
/if (${InvSlot[pack${packnum}].Item.Item[${T}].SellPrice} > 0 && !${InvSlot[pack${packnum}].Item.Item[${T}].NoDrop} && !${InvSlot[pack${packnum}].Item.Item[${T}].NoRent}) {

/ini "${MacroQuest.Server}_natesell.ini" "${InvSlot[pack${packnum}].Item.Item[${T}].Name.Left[1]}" "${InvSlot[pack${packnum}].Item.Item[${T}].Name}" "VALUED"
}
/if (${InvSlot[pack${packnum}].Item.Item[${T}].NoDrop} && !${InvSlot[pack${packnum}].Item.Item[${T}].NoRent}) {

/ini "${MacroQuest.Server}_natesell.ini" "${InvSlot[pack${packnum}].Item.Item[${T}].Name.Left[1]}" "${InvSlot[pack${packnum}].Item.Item[${T}].Name}" "ND"
}
/if (${InvSlot[pack${packnum}].Item.Item[${T}].SellPrice} == 0 !${InvSlot[pack${packnum}].Item.Item[${T}].NoDrop} && !${InvSlot[pack${packnum}].Item.Item[${T}].NoRent}) {

/ini "${MacroQuest.Server}_natesell.ini" "${InvSlot[pack${packnum}].Item.Item[${T}].Name.Left[1]}" "${InvSlot[pack${packnum}].Item.Item[${T}].Name}" "NOVALUE"
}
|SellPrice
}
/next T
}
/if (${Window[pack${packnum}].Open} && ${InvSlot[pack${packnum}].Item.Container}) /itemnotify pack${packnum} rightmouseup
/next packnum
}
/return


Title: Re: Sell hotkey
Post by: Warrchar on February 05, 2019, 10:02:01 am
Bleh, selling the blue diamonds keeps your mouse clicking finger strong for crafting them shields ;)   Nice post you two