
Originally Posted by
ohagan
bump can any1 help me?!
Code:
local SuppliesBP = "Jewelled backpack"
Code:
Module.New('Shove-pots', function(mod)
local DROP_ITEMS = {"mana potion", "great health potion", "ultimate health potion"}
for i = 0, #Container.GetAll() do -- let's find bps
search = Container.New(i)
cont = Container.New(SuppliesBP)
for spot = 0, cont:ItemCount() do
local item = search:GetItemData(spot)
if cont:isOpen() and search:Name() ~= cont:Name() then
if table.find(DROP_ITEMS, Item.GetName(item.id)) and not cont:isFull() then
search:MoveItemToContainer(spot, cont:Index(), 0, 100) -- just shove to selected bp
end
end
end
end
end)
not mine but it works