PDA

View Full Version : Bot is buying potions too fast



Atari
10-10-2016, 08:15 AM
Hi! I have problem with buying potions on xeno. He have to buy 1300 manas in config, but because of exhaust, and because of that he is doing it too fast, he always buying not enough (700 - 1000). How to do bot buy potions slower?
Here is my code:


elseif (labelName == "potions") then
Walker.Stop()
print([[Shopping]])
if (Self.ItemCount(ManaPot) < MaxMana) or (Self.ItemCount(HealthPot) < MaxHealth) then
Self.SayToNpc({"hi", "trade"}, 65)
wait(2000)
if (Self.ItemCount(ManaPot) < MaxMana) then
BuyItems(ManaPot, MaxMana)
wait(500)
BuyItems(ManaPot, MaxMana)
wait(500)
end
if (Self.ItemCount(HealthPot) < MaxHealth) then
BuyItems(HealthPot, MaxHealth)
wait(500)
end
wait(200, 500)
end
Walker.Start()
end
end

Trykon
10-10-2016, 11:14 AM
elseif(labelName == "BuyPots")then
Walker.Stop()
Self.SayToNpc("hi")
wait(200,1000)
Self.SayToNpc("trade")
wait(200, 1000)
Self.ShopBuyItemsUpTo(HpPot, HpMax)
wait(200, 1000)
Self.ShopBuyItemsUpTo(ManaPot, ManaMax)
wait(1000)
Walker.Start()

You may want to use: wait(500,1000) it depends on your ping and machine speed