Vendor Buy

When you open a vendor window you get a bunch of red items.
Some of them you will be able to use later on ... some you never will.

This fades the items you will not be able to use (or so it thinks).
Being a warrior you get the option of wearing any type of armor ... not that you would want to go against [insert favorite boss name here] while wearing the winter set... :P
So them items lower than your desired type are faded as well.

The items are still there to be bought - just faded out. If want to buy it ... you can buy it.

v.1.0003
No more bank search
Rewrote code to match recipes for your profesions too. If you cannot use the item the recipe is still hidden

v.1.0002
- Added "BankSearch": very basic and weird ...
usage:
/banksearch text <will search the bank for any itemName containing text and will apply the same "merchant effect" - seems to have problems with dashes "-" - you can use this with shift-click but may come across problems
/banksearch <with no parameter will clear the search

EDIT: I uploaded my fixed version to this web site. See the 'Optional Files' section, or just go HERE.

---
Using the Dalaran Jewelcrafter vendor Timothy Jones, Vendor Buy does not work, and recipes that I already known are not dimmed.

If I modify the following code, starting at line 174...

Code:

if(itemType=="Recipe")then
VendorBuyTooltip:ClearLines();
VendorBuyTooltip:SetHyperlink(GetMerchantItemLink(index));
local a,b,c = _G["VendorBuyTooltipTextLeft3"]:GetTextColor();
local text = _G["VendorBuyTooltipTextLeft3"]:GetText();
if ((text=="Already known")and((a>b)and(b==c))) then
item:SetAlpha(0.5);
end
end

to this...

Code:

if(itemType=="Recipe")then
VendorBuyTooltip:ClearLines();
VendorBuyTooltip:SetHyperlink(GetMerchantItemLink(index));
-- Below code is a fix for 'Already known' appearing on different lines, depending on which vendor
for i = 1, VendorBuyTooltip:NumLines() do
local text = _G["VendorBuyTooltipTextLeft"..i]:GetText();
if(text)then
local a,b,c = _G["VendorBuyTooltipTextLeft"..i]:GetTextColor();
if ((text=="Already known")and((a>b)and(b==c))) then
item:SetAlpha(0.5);
end
end
end
-- Above code is a fix for 'Already known' appearing on different lines, depending on which vendor
end

it works fine.

The code assumes that the 5th left tooltip text is always the "Already known" text (or not).