1. -- Here's some pickit stuff
  2.  
  3. function hasCertainSockets(item, sockets)
  4. for i = 0, item.stats:size() - 1 do
  5. if item.stats[i].Stat.Name == "Sockets" and item.stats[i].Value == sockets then
  6. return true
  7. end
  8. end
  9. end
  10.  
  11. function isEnhancedDef(item, percent)
  12. for i = 0, item.mods:size() - 1 do
  13. if item.mods[i].Stat.Stat == "item_armor_percent" and item.mods[i].Value >= percent then
  14. return true
  15. end
  16. end
  17. end
  18.  
  19. elseif (item.baseItem.code == "utu" or item.baseItem.code == "utp" or item.baseItem.code == "uui" or item.baseItem.code == "uar" or item.baseItem.code == "xtp") and item.quality == ItemQuality.Superior and item.flags.Ethereal == false then
  20. if isEnhancedDef(item, 15) and (hasCertainSockets(item, 0) or hasCertainSockets(item, 3) or hasCertainSockets(item, 4)) then
  21. return 7
  22. end -- pick only 0,3 or 4 socket Good non eth armors for runewords with 15ed
  23.  
  24. elseif item.baseItem.code == "7wa" and item.flags.Ethereal == true and hasCertainSockets(item, 5) and item.quality == ItemQuality.Superior and isEnhancedDef(item, 15) then
  25. return 9 -- pick only 15ed 5 soc eth zerker axe
  26.  
  27. elseif (item.baseItem.code == "7wa" or item.baseItem.code == "7cr" or item.baseItem.code == "uit") and item.quality == ItemQuality.Superior and item.flags.Ethereal == false then
  28. if isEnhancedDef(item, 15) and (hasCertainSockets(item, 0) or hasCertainSockets(item, 4) or hasCertainSockets(item, 5) or hasCertainSockets(item, 6)) then
  29. return 7
  30. end -- pick only 0,4,5 or 6 socket 15ed zerker pb or monarch
  31.  
  32. elseif item.baseItem.code == "crs" and item.flags.Ethereal == true and hasCertainSockets(item, 5) and (item.quality == ItemQuality.Normal or item.quality == ItemQuality.Superior) then
  33. return 9 -- pick only 5 soc eth crystal sword
  34.  
  35. elseif (item.baseItem.code == "pab" or item.baseItem.code == "pac" or item.baseItem.code == "pad" or item.baseItem.code == "pae" or item.baseItem.code == "paf") and (item.quality == ItemQuality.Superior or item.quality == ItemQuality.Normal) then
  36. for n = 0, item.mods:size() - 1 do
  37. if item.mods[n].Stat.Name == "Fire Resist" and item.mods[n].Value >= 40 then
  38. return 7
  39. end
  40. end -- pick only elite pally shields with 40+ res all eth or non eth and sup or normal
  41.  
  42.  
  43.  
  44.  
  45.  
  46. -- Rest are for sellitem
  47.  
  48. elseif item.baseItem.code == "uap" and item.flags.Identified == true and item.quality == ItemQuality.Unique then
  49. for i = 0, item.stats:size() - 1 do
  50. if item.stats[i].Stat.Name == "Armor Class" and not (item.stats[i].Value >= 141) then
  51. return true
  52. end
  53. end --- Only keep 141 def Shako
  54.  
  55.  
  56. elseif item.baseItem.code == "mgl" and item.flags.Identified == true and item.quality == ItemQuality.Unique then
  57. for n = 0, item.mods:size() - 1 do
  58. if item.mods[n].Stat.Name == "Magic Find" and not (item.mods[n].Value >= 40) then
  59. return true
  60. end
  61. end --- Only keep 40mf Chance Guards
  62.  
  63.  
  64. elseif item.baseItem.code == "xtb" and item.flags.Identified == true and item.quality == ItemQuality.Unique then
  65. for n = 0, item.mods:size() - 1 do
  66. if item.mods[n].Stat.Name == "Magic Find" and not (item.mods[n].Value >= 45) then
  67. return true
  68. end
  69. end --- Only keep 45mf+ War Travs
  70.  
  71.  
  72. elseif item.baseItem.code == "cm3" and item.flags.Identified == true and item.quality == ItemQuality.Unique then
  73. for n = 0, item.mods:size() - 1 do
  74. if item.mods[n].Stat.Name == "Magic Find" and not (item.mods[n].Value >= 40) then
  75. return true
  76. end
  77. end --- Only keep 40mf Gheeds