Vanilla 1.1.4 is a product of Lussumo. More Information: Documentation, Community Support.
local watchList = {
-- 10-19 weapons
[1935] = 1500000, -- Assassin's Blade
[1482] = 1300000, -- Shadowfang
[890] = 360000, -- Twisted Chanter's Staff
[2567] = 350000, -- Evocator's Blade
[1318] = 340000, -- Night Reaver
[1484] = 300000, -- Witching Stave
-- 10-19 armor
[2059] = 510000, -- Sentry Cloak
[8350] = 490000, -- The 1 Ring
[1486] = 490000, -- Tree Bark Jacket
[1121] = 400000, -- Feet of the Lynx
[12977] = 300000, -- Magefist Gloves
-- 20-29 weapons
[776] = 920000, -- Vendetta
[4454] = 490000, -- Talon of Vultros
[8226] = 450000, -- The Butcher
[4446] = 410000, -- Blackvenom Blade
[13033] = 400000, -- Zealot Blade
[3413] = 390000, -- Doomspike
[7730] = 300000, -- Cobalt Crusher
-- 20-29 armor
[9491] = 630000, -- Hotshot Pilot's Gloves
[2264] = 780000, -- Mantle of Thieves
[1978] = 530000, -- Wolfclaw Gloves
[2039] = 500000, -- Plains Ring
[9510] = 410000, -- Caverndeep Trudgers
[13108] = 400000, -- Tigerstrike Mantle
[2278] = 390000, -- Forest Tracker Epaulets
[2292] = 390000, -- Necrology Robes
[9509] = 370000, -- Petrolspill Leggings
[1491] = 360000, -- Ring of Precision
[7728] = 320000, -- Beguiler Robes
[12998] = 300000, -- Magician's Mantle
-- 30-39 weapons
[873] = 2300000, -- Staff of Jordan
[2825] = 1200000, -- Bow of Searing Arrows
[870] = 1200000, -- Fiery War Axe
[9425] = 1100000, -- Pendulum of Doom
[869] = 1000000, -- Dazzling Longsword
[1982] = 1000000, -- Nightblade
[9424] = 580000, -- Ginn-su Sword
[868] = 550000, -- Ardent Custodian
[9426] = 430000, -- Monolithic Bow
[9718] = 410000, -- Reforged Blade of Heroes
[8223] = 390000, -- Blade of the Basilisk
[13034] = 380000, -- Speedsteel Rapier
[9384] = 380000, -- Stonevault Shiv
[9392] = 330000, -- Annealed Blade
[10570] = 320000, -- Manslayer
[6327] = 320000, -- The Pacifier
[13064] = 300000, -- Jaina's Firestarter
[5756] = 300000, -- Sliverblade
-- 30-39 armor
[10583] = 1500000, -- Quillward Harness
[2955] = 1400000, -- First Mate Hat
[867] = 1100000, -- Gloves of Holy Might
[9429] = 1100000, -- Miner's Hat of the Deep
[1981] = 930000, -- Icemail Jerkin
[7755] = 740000, -- Flintrock Shoulders
[10574] = 660000, -- Corpseshroud
[5257] = 540000, -- Dark Hooded Cape
[9420] = 510000, -- Adventurer's Pith Helmet
[10328] = 500000, -- Scarlet Chestpiece
[1204] = 490000, -- The Green Tower
[9431] = 410000, -- Papal Fez
[1980] = 400000, -- Underworld Band
[9396] = 370000, -- Legguards of the Vault
[10332] = 370000, -- Scarlet Boots
[13110] = 360000, -- Wolffear Harness
[1718] = 350000, -- Basilisk Hide Pants
[2277] = 350000, -- Necromancer Leggings
[2951] = 350000, -- Ring of the Underwood
[9375] = 320000, -- Expert Goldminer's Helmet
[10581] = 310000, -- Death's Head Vestment
[13117] = 300000, -- Ogron's Sash
[13084] = 300000, -- Kaleidoscope Chain
}
local priceUpperLimit = {
[22450] = 750000, -- Void Crystal
[20725] = 75000, -- Nexus Crystal
[22449] = 180000, -- Large Prismatic Shard
[14344] = 85000, -- Large Brilliant Shard
[11178] = 75000, -- Large Radiant Shard
[11139] = 15000, -- Large Glowing Shard
[11084] = 5000, -- Large Glimmering Shard
[22448] = 50000, -- Small Prismatic Shard
[14343] = 10000, -- Small Brilliant Shard
[11177] = 50000, -- Small Radiant Shard
[11138] = 3500, -- Small Glowing Shard
[10978] = 2500, -- Small Glimmering Shard
[22446] = 52500, -- Greater Planar Essence
[16203] = 82500, -- Greater Eternal Essence
[11175] = 45000, -- Greater Nether Essence
[11135] = 6000, -- Greater Mystic Essence
[11082] = 4500, -- Greater Astral Essence
[10939] = 4500, -- Greater Magic Essence
[22447] = 17500, -- Lesser Planar Essence
[16202] = 27500, -- Lesser Eternal Essence
[11174] = 15000, -- Lesser Nether Essence
[11134] = 2000, -- Lesser Mystic Essence
[10998] = 1500, -- Lesser Astral Essence
[10938] = 1500, -- Lesser Magic Essence
[22445] = 18500, -- Arcane Dust
[16204] = 17500, -- Illusion Dust
[11176] = 5000, -- Dream Dust
[11137] = 1500, -- Vision Dust
[11083] = 1500, -- Soul Dust
[10940] = 750, -- Strange Dust
}
-- item types
local WEAPON = 0
local ARMOR = 1
-- item qualities
local UNCOMMON = 2
local RARE = 3
local EPIC = 4
-- convert an item type string to an integer type
local typeStringToType = {
["Weapon"] = WEAPON,
["Armor"] = ARMOR,
}
-- calculate value of a stack of reagents based on
-- auctioneer data and price tables above
local getReagentValue = function(itemID, itemCount)
local upperLimit = priceUpperLimit[itemID]
local adjust = 1
if not upperLimit then return nil end
local median, snapshot, snapshotCount = nil, nil, nil
local _, link = GetItemInfo(itemID)
if link then
local key = Auctioneer.ItemDB.CreateItemKeyFromLink(link)
if key then
median = Auctioneer.Statistic.GetItemHistoricalMedianBuyout(key)
snapshot, snapshotCount = Auctioneer.Statistic.GetItemSnapshotMedianBuyout(key)
end
end
median = median or upperLimit
snapshot = snapshot or upperLimit
snapshotCount = snapshotCount or 1
median = math.min(median, upperLimit)
snapshot = math.min(snapshot, upperLimit)
local snapshotWeight = 0
if snapshotCount >= 5 and snapshot < median then
snapshotWeight = math.log10(snapshotCount) / math.log10(20)
end
snapshotWeight = math.min(math.max(snapshotWeight, 0), 1)
local medianWeight = 1 - snapshotWeight
local combined = median * medianWeight + snapshot * snapshotWeight
return combined * adjust * itemCount
end
-- end getReagentValue
-- min profit for bid
local bidMinProfitRel = 0.50
local bidMinProfitAbs = 5000
-- min profit for buy
local buyMinProfitRel = 0.25
local buyMinProfitAbs = 5000
-- if buyout is close enough to low enough bid, just buy it anyway
local buyMaxBidNear = 0.01
-- adjust low bids upwards, but no closer to maximum bid than this
local bidLess = 0.20
-- assume item is worthless until proven otherwise
basePrice = 0
-- calculate reagent value
local reagentValue = getReagentValue(itemID, itemCount)
if reagentValue then
basePrice = reagentValue
reason = "Reagent"
depositCost = 0
depositRate = 0
end
-- account for AH cut
local resaleValue = basePrice * 0.95
-- decide whether or not to buy
local buyMaxRel = resaleValue * (1 - buyMinProfitRel)
local buyMaxAbs = resaleValue - buyMinProfitAbs
local bidMaxRel = resaleValue * (1 - bidMinProfitRel)
local bidMaxAbs = resaleValue - bidMinProfitAbs
if watchList[itemID] then
basePrice = watchList[itemID]
local bidMax = basePrice * 0.85
if buyPrice ~= 0 and buyPrice <= bidMax then
action = "buy"
reason = "Watch List"
elseif bidPrice ~= 0 and bidPrice <= bidMax then
action = "bid"
reason = "Watch List"
end
else
if buyPrice ~= 0 and buyPrice <= buyMaxRel and buyPrice <= buyMaxAbs then
action = "buy"
reason = reason .. " (buy)"
elseif bidPrice ~= 0 and bidPrice <= bidMaxRel and bidPrice <= bidMaxAbs then
if buyPrice ~= 0 and bidPrice >= buyPrice * (1 - buyMaxBidNear) then
action = "buy"
reason = reason .. " (buy near bid)"
else
action = "bid"
reason = reason .. " (bid, orig = " .. bidPrice .. ")"
local bidRelUp = (resaleValue * (1 - bidMinProfitRel)) * (1 - bidLess)
local bidAbsUp = (resaleValue - bidMinProfitAbs) * (1 - bidLess)
bidPrice = math.max(bidPrice, math.min(bidRelUp, bidAbsUp))
end
end
end
1 to 7 of 7