Quote Originally Posted by Chaldo View Post
@shadowart hey buddy the script used to deposit items in the new tibia ot depot but it won't anymore, any idea why?
Try adding this tothe beginning of the lua:
lua code:

function Self.OpenLocker()
-- Depot position (defaults to look pos)
local depotPos = Self.LookPosition(1)
-- Detect entry
local pos = Self.Position()
local adjacentWalkableTiles = Map.GetWalkableTiles(pos, 1)

if adjacentWalkableTiles then
for _, entryPos in ipairs(adjacentWalkableTiles) do
-- Some OTs don't detect our own position as unwalkable, so filter it out
if entryPos.x ~= pos.x or entryPos.y ~= pos.y then
depotPos = getPositionFromDirection(pos, Map.GetDirectionTo(entryPos, pos), 1)
break
end
end
end

wait(500, 1000)
local field = Container.New("Browse Field")
while (not field:isOpen()) do -- locker isn't open
Self.BrowseField(depotPos.x, depotPos.y, depotPos.z)
wait(800, 1000)
field = Container.New("Browse Field")
end
while (field:UseItem(0, true) ~= 1) do
wait(100)
end
end


The method that I have included in my scripts relies on the depot not being trashed, but the above code should work regardless.