-- Start in Varrock West bank

MoveToRandomly(279,553,279,552)
MoveToRandomly(280,552,280,553)

---- Banking
RepeatNextCommandUntilQuestMenu(100,8)
SetVarMyX(%x)
GoToIfVarAboveNum(@decrease,%x,281)
AddVarNum(%x,1)
GoTo(@DoAction)
@decrease:
AddVarNum(%x,-1)
@DoAction:
SetVarMyY(%y)
ActionVarVar(%x,%y)
TalkToNPC(936,938,939,941,942,943)
Answer(0)
WaitForBankWindow(50)
DepositEverything()
Wait(30)
--- Withdraw 2 coals and 1 iron
@TakeOres:
Withdraw(155,1)
Withdraw(155,1)
Withdraw(151,1)
Wait(5)
GoToIfBagFull(@EndWithdraw)
GoTo(@TakeOres)
@EndWithdraw:
Wait(10)
CloseBank()
Wait(10)

MoveToRandomly(280,552,280,553)
MoveToRandomly(279,553,279,552)

MoveToRandomly(266,551,265,551)
MoveToRandomly(264,544,265,544)
MoveToRandomly(263,544,262,544,261,544)

--- Smelt
@SmeltNext:
GoToIfCountInInventoryGreater(@CheckIron,1,155)
GoTo(@StopSmelt)
@CheckIron:
GoToIfCountInInventoryGreater(@StartSmelt,0,151)
GoTo(@StopSmelt)
@StartSmelt:
SmeltOre(259,545,258,546,155)
Wait(30)
GoTo(@SmeltNext)
@StopSmelt:

MoveToRandomly(263,544,262,544,261,544)
MoveToRandomly(264,544,265,544)
MoveToRandomly(266,551,265,551)


