Advertisement
Guest User

Untitled

a guest
Jan 14th, 2013
22
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.21 KB | None | 0 0
  1. reachgrounditem("depot")
  2. wait(1000,2000)
  3. openitem("depot")
  4. wait(700,900)
  5. openitem(3502, "locker")
  6. wait(700,900)
  7. openitem(DepotBP, "depot chest")
  8. wait(700,900)
  9.  
  10. local CONFIG = {
  11. LOOT_BACKPACK = LootBP,
  12.  
  13. STACKABLE_BACKPACK = DPStackBP,
  14. STACKABLE_BACKPACK_AMOUNT = 2,
  15.  
  16. NOT_STACKABLE_BACKPACK = DPRareBP,
  17. NOT_STACKABLE_BACKPACK_AMOUNT = 18,
  18.  
  19. DEPOSIT_ITEMS = {"Cheese Cutter", "bola", "Earflap", "small emerald", "Cheesy Figurine","giant shimmering pearl", "rat god doll", "ratana", "life preserver", "spike shield", "spiky club", "Leather Harness"},
  20. }
  21.  
  22. local NOT_STACKABLE_LAST_ON_TO, ITEM_INDEX = 0, 1
  23.  
  24. while (#CONFIG.DEPOSIT_ITEMS >= ITEM_INDEX) do
  25. if (type(CONFIG.DEPOSIT_ITEMS[ITEM_INDEX]) == "string") then
  26. local ITEM_ID = itemid(CONFIG.DEPOSIT_ITEMS[ITEM_INDEX])
  27.  
  28. if (ITEM_ID > 0) then
  29. CONFIG.DEPOSIT_ITEMS[ITEM_INDEX], ITEM_INDEX = ITEM_ID, ITEM_INDEX + 1
  30. else
  31. table.remove(CONFIG.DEPOSIT_ITEMS, ITEM_INDEX)
  32. end
  33. elseif (type(CONFIG.DEPOSIT_ITEMS[ITEM_INDEX]) == "number") then
  34. if (CONFIG.DEPOSIT_ITEMS[ITEM_INDEX] > 0) then
  35. ITEM_INDEX = ITEM_INDEX + 1
  36. else
  37. table.remove(CONFIG.DEPOSIT_ITEMS, ITEM_INDEX)
  38. end
  39. else
  40. table.remove(CONFIG.DEPOSIT_ITEMS, ITEM_INDEX)
  41. end
  42. end
  43.  
  44. local ITEM_COUNT_AFTER = itemcount(DEPOSIT_ITEM, CONFIG.LOOT_BACKPACK)
  45.  
  46. if (ITEM_COUNT_BEFORE == ITEM_COUNT_AFTER and ITEM_COUNT_AFTER > 0) then
  47. STACKABLE_LAST_ON_TO = STACKABLE_LAST_ON_TO + 1
  48. elseif (ITEM_COUNT_AFTER == 0) then
  49. break
  50. end
  51. end
  52. else
  53. while (CONFIG.NOT_STACKABLE_BACKPACK_AMOUNT > NOT_STACKABLE_LAST_ON_TO) do
  54. local ITEM_COUNT_BEFORE = itemcount(DEPOSIT_ITEM, CONFIG.LOOT_BACKPACK)
  55.  
  56. moveitemsonto(DEPOSIT_ITEM, "all", CONFIG.NOT_STACKABLE_BACKPACK, 100, NOT_STACKABLE_LAST_ON_TO) wait(500, 1000)
  57.  
  58. local ITEM_COUNT_AFTER = itemcount(DEPOSIT_ITEM, CONFIG.LOOT_BACKPACK)
  59.  
  60. if (ITEM_COUNT_BEFORE == ITEM_COUNT_AFTER and ITEM_COUNT_AFTER > 0) then
  61. NOT_STACKABLE_LAST_ON_TO = NOT_STACKABLE_LAST_ON_TO + 1
  62. elseif (ITEM_COUNT_AFTER == 0) then
  63. break
  64. end
  65. end
  66. end
  67. end
  68. end
  69.  
  70. if (itemcount(CONFIG.LOOT_BACKPACK, CONFIG.LOOT_BACKPACK) > 0) then
  71. openitem(CONFIG.LOOT_BACKPACK, CONFIG.LOOT_BACKPACK, false) wait(2000, 3000)
  72. else
  73. break
  74. end
  75.  
  76. wait(100)
  77. end
  78.  
  79.  
  80. setsettings("Settings\\Cavebot\\Settings\\OpenNext Bp", "yes")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement