• 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!

OTClient

athenso

Average Coder
Joined
May 31, 2011
Messages
155
Solutions
3
Reaction score
23
I wrote an auto loot script and it is not working right. I have edited my tibia.dat and added custom items. I dont think that is the problem though (they are replaced in all appropriate directories.
The commands in talk action do work as they should. Talkaction wise, everything is working. This is just an OTClient issue that is above my knowledge

the useThing:getServerId() is not working right, it always returns an error. Is there a different way i can call this function?
Code:
  if lookThing and not lookThing:isCreature() and not lookThing:isNotMoveable() and lookThing:isPickupable() then
    menu:addOption(tr('Loot'), function() g_game.talk('!autoloot add,' .. useThing:getServerId()) end)
    menu:addSeparator()
    menu:addOption(tr('Trade with ...'), function() startTradeWith(lookThing) end)
  
  end
 
Last edited:
Struggled for hours....went to show roomate the idea in "theory" and it worked like a charm. Guess the code is right and needed a client reload.
 
Back
Top