PDA

View Full Version : Withdraw from depot



BIRDIE13
11-24-2015, 11:56 PM
Hello! I'm making my first 100% afk hunting script. Can anyone explain to me how i withdraw items from the depot? I'd like to withdraw from example backpack nr3 and nr4. Thanks

Oscagi
11-26-2015, 12:11 PM
local AmmoUse = "Assassin Star"
local AmmoMax = 200
local AmmoBp = "Purple Backpack"
----------------------

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


BIRDIE13