Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
i have been trying to use the script below but i keep getting this error, anyone know how to fix it?
local npc = getCreatureByName("Npc Name")
local idpot = 3131
local potcount = 1000
if npc then
if not NPC.isTrading() then
say("hi")
schedule(1000, function() NPC.say("trade") end)
else
schedule(1000, function() NPC.buy(idpot, 100) end)
end
delay(2000)
end
if player:getItemsCount(potid) <= potcount then
return "retry"
end
return true
Anyone can help me? Im trying to make a Item Mover from a depot to my backpack. Heres my code:
Lua:
local itemIDs = {12192} -- populate this table with items IDs you would like to move to the specified backpack
local backpackToMove = 2853
local containers = g_game.getContainers()
macro (500, "Move items", function ()
local function findContainer()
for _, container in pairs(containers) do
if container:getId() == backpackToMove then
return container
end
end
end
local containerToMove = findContainer()
if not containerToMove then return end
for i = 1, #containers do
local items = containers[i]:getItems()
for _, item in pairs(items) do
if table.find(itemIDs, item:getId()) then
g_game.move(item:getId(), containerToMove:getSlotPosition(math.max(0, #items-1)), item:getCount())
return
end
end
end
end)
Anyone can help me? Im trying to make a Item Mover from a depot to my backpack. Heres my code:
Lua:
local itemIDs = {12192} -- populate this table with items IDs you would like to move to the specified backpack
local backpackToMove = 2853
local containers = g_game.getContainers()
macro (500, "Move items", function ()
local function findContainer()
for _, container in pairs(containers) do
if container:getId() == backpackToMove then
return container
end
end
end
local containerToMove = findContainer()
if not containerToMove then return end
for i = 1, #containers do
local items = containers[i]:getItems()
for _, item in pairs(items) do
if table.find(itemIDs, item:getId()) then
g_game.move(item:getId(), containerToMove:getSlotPosition(math.max(0, #items-1)), item:getCount())
return
end
end
end
end)
local REQUIRE_LEVEL = 950
local RESET_COMMAND = "!reset"
local REQUIRE_LEVEL_MRESET = 5000
local MRESET_COMMAND = "!mreset now"
local REQUIRE_RESETS = 50
local resetCount = 0
macro(100, "Reset", function()
local currentLevel = level()
if currentLevel >= REQUIRE_LEVEL then
if resetCount < REQUIRE_RESETS then
gotoLabel("upar")
say(RESET_COMMAND)
delay(800)
gotoLabel("safe_place") -- Vai para a label "safe_place" antes de usar !reset
resetCount = resetCount + 1
elseif currentLevel >= REQUIRE_LEVEL_MRESET then
gotoLabel("up_five_k")
say(MRESET_COMMAND)
delay(800)
resetCount = 0 -- Resetar o contador após !mreset now
end
end
end)
local REQUIRE_LEVEL = 950
local RESET_COMMAND = "!reset"
local REQUIRE_LEVEL_MRESET = 5000
local MRESET_COMMAND = "!mreset now"
local REQUIRE_RESETS = 50
local resetCount = 0
macro(100, "Reset", function()
local currentLevel = level()
if currentLevel >= REQUIRE_LEVEL then
if resetCount < REQUIRE_RESETS then
gotoLabel("upar")
say(RESET_COMMAND)
delay(800)
gotoLabel("safe_place") -- Vai para a label "safe_place" antes de usar !reset
resetCount = resetCount + 1
elseif currentLevel >= REQUIRE_LEVEL_MRESET then
gotoLabel("up_five_k")
say(MRESET_COMMAND)
delay(800)
resetCount = 0 -- Resetar o contador após !mreset now
end
end
end)
Hello i hope someone is still here, i need a help with script for "shovel" i can call, i need to use item on dead monster and then item is collecting to container soul from monster, someone can help ?
Post automatically merged:
Hello i hope someone is still here, i need a help with script for "shovel" i can call, i need to use item on dead monster and then item is collecting to container soul from monster, someone can help ?