Paladyn
05-20-2016, 05:11 PM
I´m having this problem that my script accepts into the bot with no errors. But when I´m having Labels in my walker it won't do what I have told the bot in the script:
registerEventListener(WALKER_SELECTLABEL, "onWalkerSelectLabel")
function onWalkerSelectLabel(labelName)
if (labelName == "Manas") then
delayWalker(3000)
Self.Say("Hi")
sleep(math.random(700, 1400))
Self.SayToNpc("Trade")
sleep(math.random(700, 1400))
Self.ShopSellAllItems("empty potion flask")
sleep(math.random(700, 1400))
Self.ShopBuyItemsUpTo("mana potion", 40)
end
if (labelName == "Withdraw") then
delayWalker(3000)
Self.Say("Hi")
sleep(math.random(700, 1400))
Self.SayToNpc("deposit all")
sleep(math.random(700, 1400))
Self.SayToNpc("withdraw 2400")
sleep(math.random(700, 1400))
Self.SayToNpc("Yes")
also this seems to not work correctly:
if (labelName == "Check") then
delayWalker(3000)
if (Self.Cap(20) < MinCap) or ((Self.ItemCount(268) < 5)) or ((Self.ItemCount(7378) <5)) (LeaveUponGoldAmount == true) and ((Self.ItemCount(GoldID) >= 3000)) then
gotoLabel("Gobank")
else
gotoLabel("Start")
end
So here it will just walk to the bank for withdraw and do nothing just moving on to the next thing to do on walker.
registerEventListener(WALKER_SELECTLABEL, "onWalkerSelectLabel")
function onWalkerSelectLabel(labelName)
if (labelName == "Manas") then
delayWalker(3000)
Self.Say("Hi")
sleep(math.random(700, 1400))
Self.SayToNpc("Trade")
sleep(math.random(700, 1400))
Self.ShopSellAllItems("empty potion flask")
sleep(math.random(700, 1400))
Self.ShopBuyItemsUpTo("mana potion", 40)
end
if (labelName == "Withdraw") then
delayWalker(3000)
Self.Say("Hi")
sleep(math.random(700, 1400))
Self.SayToNpc("deposit all")
sleep(math.random(700, 1400))
Self.SayToNpc("withdraw 2400")
sleep(math.random(700, 1400))
Self.SayToNpc("Yes")
also this seems to not work correctly:
if (labelName == "Check") then
delayWalker(3000)
if (Self.Cap(20) < MinCap) or ((Self.ItemCount(268) < 5)) or ((Self.ItemCount(7378) <5)) (LeaveUponGoldAmount == true) and ((Self.ItemCount(GoldID) >= 3000)) then
gotoLabel("Gobank")
else
gotoLabel("Start")
end
So here it will just walk to the bank for withdraw and do nothing just moving on to the next thing to do on walker.