Fixed bug with TargetBot.useAttackItem

This commit is contained in:
OTCv8 2020-04-16 00:36:47 +02:00
parent 401eb76bba
commit 76d6f2ce7d
2 changed files with 2 additions and 2 deletions

View File

@ -181,7 +181,7 @@ macro(250, function()
for __, item in ipairs(container:getItems()) do for __, item in ipairs(container:getItems()) do
if item:getId() == autoEquip.item1 or item:getId() == autoEquip.item2 then if item:getId() == autoEquip.item1 or item:getId() == autoEquip.item2 then
g_game.move(item, {x=65535, y=autoEquip.slot, z=0}, item:getCount()) g_game.move(item, {x=65535, y=autoEquip.slot, z=0}, item:getCount())
delay(1000) -- don't call it to often delay(1000) -- don't call it too often
return return
end end
end end

View File

@ -249,7 +249,7 @@ TargetBot.useAttackItem = function(item, subType, target, delay)
if not tmpItem then return end if not tmpItem then return end
g_game.useWith(tmpItem, target, subType) -- using item from bp g_game.useWith(tmpItem, target, subType) -- using item from bp
else else
g_game.useInventoryItemWith(healingInfo.item, target, subType) -- hotkey g_game.useInventoryItemWith(item, target, subType) -- hotkey
end end
lastRuneAttack = now lastRuneAttack = now
end end