PDA

View Full Version : Withdraw Stuck



derkonsito
02-10-2016, 03:25 AM
Hey guys im using this withdraw code, it withdraw the spears perfectly but then stays trying to withdraw more and never moves... i guess its because the bot instantly equips them, can someone help me making it not to stuck! Thanks


elseif (labelName == "GetAmmo") then
Self.ReachDepot()
wait(200, 300)
Container.GetByName("Locker"):OpenChildren({3502, true}) -- Opens depot chest
wait(500,600)
Container.GetByName("Locker"):Close() -- Closes locker
wait(500,600)
Self.WithdrawItems(AmmoDP, {AmmoID, 0, MaxAmmo-Self.ItemCount(AmmoID)}) -- 3 means from third backpack in DP, Ammo is ammunition ID, 0 means to first backpack you hold, last "number" is an amount to withdraw.
wait(200,400)

derkonsito
02-11-2016, 03:47 AM
Bump Anyone?:(

Oscagi
02-12-2016, 01:01 PM
AmmoMax = 200
AmmoUse = "Assassin Stars"
AmmoBp = "Purple Backpack"

registerEventListener(WALKER_SELECTLABEL, "onWalkerSelectLabel")
function onWalkerSelectLabel(labelName)
if (labelName == "WithdrawAmmo") then
if Self.ItemCount(Item.GetID(AmmoUse) < AmmoMax) then
AmmoToWithdraw = (AmmoMax - Self.ItemCount(AmmoUse))
Self.WithdrawItems(0, {Item.GetID(AmmoUse), AmmoBp, AmmoToWithdraw}) -- 0, Is the spot of bp on Depot.
end
end
end


Try to use Self.WithdrawItems.


/Oscagi