Quantcast
WoWInterface - View Single Post - My LUA code dont work in new API 8.3.0 [ auction ] ]
View Single Post
05-10-20, 04:51 PM   #6
lungdesire
A Deviate Faerie Dragon
Join Date: May 2020
Posts: 13
please talk to me how work tis code?

local auctions = {}

local function OnEvent(self, event)
if event == "AUCTION_HOUSE_SHOW" then
C_AuctionHouse.ReplicateItems()
elseif event == "REPLICATE_ITEM_LIST_UPDATE" then
wipe(auctions)
for i = 1, C_AuctionHouse.GetNumReplicateItems() do
auctions[i] = {C_AuctionHouse.GetReplicateItemInfo(i)}
end
print(format("Queried %d items", #auctions))
end
end

local f = CreateFrame("Frame")
f:RegisterEvent("AUCTION_HOUSE_SHOW")
f:RegisterEvent("REPLICATE_ITEM_LIST_UPDATE")
f:SetScript("OnEvent", OnEvent)
  Reply With Quote