-
-
Save orlp/744141 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
local addmsg = ChatFrame1.AddMessage | |
local function hook(frame, text, ...) | |
if text:find(gsub(ERR_AUCTION_SOLD_S,'%%s', '')) then -- "A buyer has been found for your auction of %s." | |
local itemname = text:match(gsub(ERR_AUCTION_SOLD_S, '%%s', '(.+)')) | |
text = "|cffef4341"..BUTTON_LAG_AUCTIONHOUSE.."|r - |cffBCD8FF"..ITEM_SOLD_COLON.."|r " | |
local _, solditem = GetItemInfo(itemname) | |
if solditem then | |
text = text..solditem | |
else | |
text = text..itemname | |
end | |
end | |
return addmsg(frame, text, ...) | |
end | |
for i = 1, NUM_CHAT_WINDOWS do | |
_G["ChatFrame"..i].AddMessage = hook | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment