Advertisement
Bleckpan

AH Query GM

Jul 30th, 2011
142
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.42 KB | None | 0 0
  1.  
  2. local numBatchAuctions, totalAuctions
  3. local Item_Number = 1
  4. local name, _, count, _, _, _, minBid, _, buyoutPrice, _, _, _, _
  5. local Glyphs_Called = 0
  6. Glyph_Pages = 5
  7. Glyph_Page = 1
  8.  
  9. local GlyphMaster = CreateFrame ("FRAME", "GlyphMaster", UIParent, nil)
  10. GlyphMaster:RegisterEvent("AUCTION_ITEM_LIST_UPDATE")
  11. GlyphMaster:RegisterEvent("ADDON_LOADED")
  12. GlyphMaster:SetScript("OnEvent", function (self, event)
  13. if event == "ADDON_LOADED" then
  14.  
  15. --if not Glyph_List_Names then
  16. Glyph_List_Names = {}
  17. --elseif not Glyph_Count then
  18. Glyph_Count = 0
  19. --elseif not Glyph_List_Count then
  20. Glyph_List_Count = {}
  21. --elseif not Glyph_List then
  22. Glyph_List = {}
  23. --elseif not Glyph_List_MinBid then
  24. Glyph_List_MinBid = {}
  25. --elseif not Glyph_List_MinBO then
  26. Glyph_List_MinBO = {}
  27.  
  28. elseif event == "AUCTION_ITEM_LIST_UPDATE" then
  29. --if Glyphs_Called == 0 then return end
  30. numBatchAuctions, wholeCount = GetNumAuctionItems("list")
  31.  for Item_Number = 1, wholeCount do
  32.  name, _, _, _, _, _, _, _, buyoutPrice, _, _, _, _ = GetAuctionItemInfo("list", Item_Number)
  33.   if string.find(name, "Glyph") == 1 then
  34.   Glyph_List[Glyph_Count] = {name, buyoutPrice}
  35.   Glyph_Count = Glyph_Count + 1
  36.   end
  37.  end
  38. end
  39. --Glyphs_Called = 0
  40. --end
  41. end
  42. )
  43.  
  44. SLASH_GlyphMaster1 = "/GMaster"
  45. SLASH_GlyphMaster2 = "/GlyphM"
  46.  
  47. function SlashCmdList.GlyphMaster ()
  48.  QueryAuctionItems("Glyph", nil, nil, nil, nil, nil, nil, false, nil, true)
  49.  --Glyphs_Called = 1
  50. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement